[Libreoffice-commits] core.git: accessibility/inc accessibility/source avmedia/source include/avmedia sc/source sd/source sw/source

Noel Grandin noel.grandin at collabora.co.uk
Fri Apr 28 11:57:07 UTC 2017


 accessibility/inc/standard/vclxaccessiblelist.hxx    |    7 +------
 accessibility/source/standard/vclxaccessiblelist.cxx |    9 ++-------
 avmedia/source/framework/mediacontrol.cxx            |    3 +--
 avmedia/source/viewer/mediawindow.cxx                |    3 +--
 include/avmedia/mediawindow.hxx                      |    3 +--
 sc/source/ui/drawfunc/fuins1.cxx                     |    2 +-
 sd/source/ui/func/fuinsert.cxx                       |    2 +-
 sw/source/uibase/shells/grfshex.cxx                  |    2 +-
 8 files changed, 9 insertions(+), 22 deletions(-)

New commits:
commit dc735109bf44754b59a6fcdbcb8171d1bbf82ba3
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date:   Fri Apr 28 11:19:09 2017 +0200

    loplugin:checkunusedparams in accessibility and avmedia
    
    Change-Id: I94df9a65578792fb06f3b3259603f70ca1e0b3db
    Reviewed-on: https://gerrit.libreoffice.org/37059
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/accessibility/inc/standard/vclxaccessiblelist.hxx b/accessibility/inc/standard/vclxaccessiblelist.hxx
index 9d77fe7a526a..2399d5d69603 100644
--- a/accessibility/inc/standard/vclxaccessiblelist.hxx
+++ b/accessibility/inc/standard/vclxaccessiblelist.hxx
@@ -164,13 +164,8 @@ protected:
 
     /** Call this method when the item list has been changed, i.e. items
         have been deleted or inserted.
-        @param bItemInserted
-            Indicate whether items have been inserted (TRUE) or removed (FALSE).
-        @param nIndex
-            Index of the new or removed item.  A value of -1 indicates that
-            the whole list has been cleared.
     */
-    void HandleChangedItemList (bool bItemInserted, sal_Int32 nIndex);
+    void HandleChangedItemList();
 
     // VCLXAccessibleComponent
     virtual css::awt::Rectangle implGetBounds(  ) override;
diff --git a/accessibility/source/standard/vclxaccessiblelist.cxx b/accessibility/source/standard/vclxaccessiblelist.cxx
index d314879765cf..0da281044449 100644
--- a/accessibility/source/standard/vclxaccessiblelist.cxx
+++ b/accessibility/source/standard/vclxaccessiblelist.cxx
@@ -389,14 +389,9 @@ void VCLXAccessibleList::ProcessWindowEvent (const VclWindowEvent& rVclWindowEve
 
         case VclEventId::ListboxItemRemoved:
         case VclEventId::ComboboxItemRemoved:
-            HandleChangedItemList (false, reinterpret_cast<sal_IntPtr>(
-                rVclWindowEvent.GetData()));
-            break;
-
         case VclEventId::ListboxItemAdded:
         case VclEventId::ComboboxItemAdded:
-            HandleChangedItemList (true, reinterpret_cast<sal_IntPtr>(
-                rVclWindowEvent.GetData()));
+            HandleChangedItemList();
             break;
         case VclEventId::ControlGetFocus:
             {
@@ -515,7 +510,7 @@ Reference<XAccessible> VCLXAccessibleList::CreateChild (sal_Int32 nPos)
 }
 
 
-void VCLXAccessibleList::HandleChangedItemList (bool /*bItemInserted*/, sal_Int32 /*nIndex*/)
+void VCLXAccessibleList::HandleChangedItemList()
 {
     clearItems();
     NotifyAccessibleEvent (
diff --git a/avmedia/source/framework/mediacontrol.cxx b/avmedia/source/framework/mediacontrol.cxx
index 18d4f5599618..85d3f95dd97b 100644
--- a/avmedia/source/framework/mediacontrol.cxx
+++ b/avmedia/source/framework/mediacontrol.cxx
@@ -294,8 +294,7 @@ IMPL_LINK( MediaControl, implSelectHdl, ToolBox*, p, void )
         {
             OUString aURL;
 
-             if (MediaWindow::executeMediaURLDialog(
-                         GetParent(), aURL, nullptr))
+             if (MediaWindow::executeMediaURLDialog(aURL, nullptr))
              {
                  if( !MediaWindow::isMediaURL( aURL, ""/*TODO?*/, true ) )
                     MediaWindow::executeFormatErrorBox( this );
diff --git a/avmedia/source/viewer/mediawindow.cxx b/avmedia/source/viewer/mediawindow.cxx
index 71227b86265c..54c7308976b8 100644
--- a/avmedia/source/viewer/mediawindow.cxx
+++ b/avmedia/source/viewer/mediawindow.cxx
@@ -209,8 +209,7 @@ void MediaWindow::getMediaFilters( FilterNameVector& rFilterNameVector )
 }
 
 
-bool MediaWindow::executeMediaURLDialog(vcl::Window*,
-        OUString& rURL, bool *const o_pbLink)
+bool MediaWindow::executeMediaURLDialog(OUString& rURL, bool *const o_pbLink)
 {
     ::sfx2::FileDialogHelper        aDlg( o_pbLink
             ? ui::dialogs::TemplateDescription::FILEOPEN_LINK_PREVIEW
diff --git a/include/avmedia/mediawindow.hxx b/include/avmedia/mediawindow.hxx
index c24fcdcfb589..f5dd652f2cd6 100644
--- a/include/avmedia/mediawindow.hxx
+++ b/include/avmedia/mediawindow.hxx
@@ -98,8 +98,7 @@ namespace avmedia
         static void         getMediaFilters( FilterNameVector& rFilterNameVector );
         /// @param o_pbLink if not 0, this is an "insert" dialog: display link
         ///                 checkbox and store its state in *o_pbLink
-        static bool         executeMediaURLDialog( vcl::Window* pParent,
-                OUString& rURL, bool *const o_pbLink );
+        static bool         executeMediaURLDialog( OUString& rURL, bool *const o_pbLink );
         static void         executeFormatErrorBox( vcl::Window* pParent );
         static bool         isMediaURL( const OUString& rURL, const OUString& rReferer, bool bDeep = false, Size* pPreferredSizePixel = nullptr );
 
diff --git a/sc/source/ui/drawfunc/fuins1.cxx b/sc/source/ui/drawfunc/fuins1.cxx
index 12b6b75614cc..7b4302b67c93 100644
--- a/sc/source/ui/drawfunc/fuins1.cxx
+++ b/sc/source/ui/drawfunc/fuins1.cxx
@@ -331,7 +331,7 @@ FuInsertMedia::FuInsertMedia( ScTabViewShell*   pViewSh,
 
     bool bLink(true);
     if (bAPI ||
-        ::avmedia::MediaWindow::executeMediaURLDialog(pWindow, aURL, & bLink))
+        ::avmedia::MediaWindow::executeMediaURLDialog(aURL, & bLink))
     {
         Size aPrefSize;
 
diff --git a/sd/source/ui/func/fuinsert.cxx b/sd/source/ui/func/fuinsert.cxx
index 5eb0ae16e9ff..b3d431a98b25 100644
--- a/sd/source/ui/func/fuinsert.cxx
+++ b/sd/source/ui/func/fuinsert.cxx
@@ -714,7 +714,7 @@ void FuInsertAVMedia::DoExecute( SfxRequest& rReq )
 
     bool bLink(true);
     if (bAPI ||
-        ::avmedia::MediaWindow::executeMediaURLDialog(mpWindow, aURL, & bLink))
+        ::avmedia::MediaWindow::executeMediaURLDialog(aURL, & bLink))
     {
         Size aPrefSize;
 
diff --git a/sw/source/uibase/shells/grfshex.cxx b/sw/source/uibase/shells/grfshex.cxx
index 0559e218a322..9c96068e8290 100644
--- a/sw/source/uibase/shells/grfshex.cxx
+++ b/sw/source/uibase/shells/grfshex.cxx
@@ -77,7 +77,7 @@ bool SwTextShell::InsertMediaDlg( SfxRequest& rReq )
 
     bool bLink(true);
     if (bAPI ||
-        ::avmedia::MediaWindow::executeMediaURLDialog(pWindow, aURL, & bLink))
+        ::avmedia::MediaWindow::executeMediaURLDialog(aURL, & bLink))
     {
         Size aPrefSize;
 


More information about the Libreoffice-commits mailing list