Kaydet (Commit) dc735109 authored tarafından Noel Grandin's avatar Noel Grandin

loplugin:checkunusedparams in accessibility and avmedia

Change-Id: I94df9a65578792fb06f3b3259603f70ca1e0b3db
Reviewed-on: https://gerrit.libreoffice.org/37059Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 032e7a4b
...@@ -164,13 +164,8 @@ protected: ...@@ -164,13 +164,8 @@ protected:
/** Call this method when the item list has been changed, i.e. items /** Call this method when the item list has been changed, i.e. items
have been deleted or inserted. 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 // VCLXAccessibleComponent
virtual css::awt::Rectangle implGetBounds( ) override; virtual css::awt::Rectangle implGetBounds( ) override;
......
...@@ -389,14 +389,9 @@ void VCLXAccessibleList::ProcessWindowEvent (const VclWindowEvent& rVclWindowEve ...@@ -389,14 +389,9 @@ void VCLXAccessibleList::ProcessWindowEvent (const VclWindowEvent& rVclWindowEve
case VclEventId::ListboxItemRemoved: case VclEventId::ListboxItemRemoved:
case VclEventId::ComboboxItemRemoved: case VclEventId::ComboboxItemRemoved:
HandleChangedItemList (false, reinterpret_cast<sal_IntPtr>(
rVclWindowEvent.GetData()));
break;
case VclEventId::ListboxItemAdded: case VclEventId::ListboxItemAdded:
case VclEventId::ComboboxItemAdded: case VclEventId::ComboboxItemAdded:
HandleChangedItemList (true, reinterpret_cast<sal_IntPtr>( HandleChangedItemList();
rVclWindowEvent.GetData()));
break; break;
case VclEventId::ControlGetFocus: case VclEventId::ControlGetFocus:
{ {
...@@ -515,7 +510,7 @@ Reference<XAccessible> VCLXAccessibleList::CreateChild (sal_Int32 nPos) ...@@ -515,7 +510,7 @@ Reference<XAccessible> VCLXAccessibleList::CreateChild (sal_Int32 nPos)
} }
void VCLXAccessibleList::HandleChangedItemList (bool /*bItemInserted*/, sal_Int32 /*nIndex*/) void VCLXAccessibleList::HandleChangedItemList()
{ {
clearItems(); clearItems();
NotifyAccessibleEvent ( NotifyAccessibleEvent (
......
...@@ -294,8 +294,7 @@ IMPL_LINK( MediaControl, implSelectHdl, ToolBox*, p, void ) ...@@ -294,8 +294,7 @@ IMPL_LINK( MediaControl, implSelectHdl, ToolBox*, p, void )
{ {
OUString aURL; OUString aURL;
if (MediaWindow::executeMediaURLDialog( if (MediaWindow::executeMediaURLDialog(aURL, nullptr))
GetParent(), aURL, nullptr))
{ {
if( !MediaWindow::isMediaURL( aURL, ""/*TODO?*/, true ) ) if( !MediaWindow::isMediaURL( aURL, ""/*TODO?*/, true ) )
MediaWindow::executeFormatErrorBox( this ); MediaWindow::executeFormatErrorBox( this );
......
...@@ -209,8 +209,7 @@ void MediaWindow::getMediaFilters( FilterNameVector& rFilterNameVector ) ...@@ -209,8 +209,7 @@ void MediaWindow::getMediaFilters( FilterNameVector& rFilterNameVector )
} }
bool MediaWindow::executeMediaURLDialog(vcl::Window*, bool MediaWindow::executeMediaURLDialog(OUString& rURL, bool *const o_pbLink)
OUString& rURL, bool *const o_pbLink)
{ {
::sfx2::FileDialogHelper aDlg( o_pbLink ::sfx2::FileDialogHelper aDlg( o_pbLink
? ui::dialogs::TemplateDescription::FILEOPEN_LINK_PREVIEW ? ui::dialogs::TemplateDescription::FILEOPEN_LINK_PREVIEW
......
...@@ -98,8 +98,7 @@ namespace avmedia ...@@ -98,8 +98,7 @@ namespace avmedia
static void getMediaFilters( FilterNameVector& rFilterNameVector ); static void getMediaFilters( FilterNameVector& rFilterNameVector );
/// @param o_pbLink if not 0, this is an "insert" dialog: display link /// @param o_pbLink if not 0, this is an "insert" dialog: display link
/// checkbox and store its state in *o_pbLink /// checkbox and store its state in *o_pbLink
static bool executeMediaURLDialog( vcl::Window* pParent, static bool executeMediaURLDialog( OUString& rURL, bool *const o_pbLink );
OUString& rURL, bool *const o_pbLink );
static void executeFormatErrorBox( vcl::Window* pParent ); static void executeFormatErrorBox( vcl::Window* pParent );
static bool isMediaURL( const OUString& rURL, const OUString& rReferer, bool bDeep = false, Size* pPreferredSizePixel = nullptr ); static bool isMediaURL( const OUString& rURL, const OUString& rReferer, bool bDeep = false, Size* pPreferredSizePixel = nullptr );
......
...@@ -331,7 +331,7 @@ FuInsertMedia::FuInsertMedia( ScTabViewShell* pViewSh, ...@@ -331,7 +331,7 @@ FuInsertMedia::FuInsertMedia( ScTabViewShell* pViewSh,
bool bLink(true); bool bLink(true);
if (bAPI || if (bAPI ||
::avmedia::MediaWindow::executeMediaURLDialog(pWindow, aURL, & bLink)) ::avmedia::MediaWindow::executeMediaURLDialog(aURL, & bLink))
{ {
Size aPrefSize; Size aPrefSize;
......
...@@ -714,7 +714,7 @@ void FuInsertAVMedia::DoExecute( SfxRequest& rReq ) ...@@ -714,7 +714,7 @@ void FuInsertAVMedia::DoExecute( SfxRequest& rReq )
bool bLink(true); bool bLink(true);
if (bAPI || if (bAPI ||
::avmedia::MediaWindow::executeMediaURLDialog(mpWindow, aURL, & bLink)) ::avmedia::MediaWindow::executeMediaURLDialog(aURL, & bLink))
{ {
Size aPrefSize; Size aPrefSize;
......
...@@ -77,7 +77,7 @@ bool SwTextShell::InsertMediaDlg( SfxRequest& rReq ) ...@@ -77,7 +77,7 @@ bool SwTextShell::InsertMediaDlg( SfxRequest& rReq )
bool bLink(true); bool bLink(true);
if (bAPI || if (bAPI ||
::avmedia::MediaWindow::executeMediaURLDialog(pWindow, aURL, & bLink)) ::avmedia::MediaWindow::executeMediaURLDialog(aURL, & bLink))
{ {
Size aPrefSize; Size aPrefSize;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment