summaryrefslogtreecommitdiff
path: root/sfx2/source/control
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-05-03 11:48:32 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-05-04 12:05:29 +0200
commitd4e9fe5a733f9c3a3c0b673379739c768075b465 (patch)
treeaa03f07d97a59053c374f590818aa942f120848e /sfx2/source/control
parenta4b581bb996142d2906f23161ec673f958511649 (diff)
loplugin:checkunusedparams in sfx2
Change-Id: Iea88ddd619f10a2a2586ee24edbf07e246dcbb49 Reviewed-on: https://gerrit.libreoffice.org/37191 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sfx2/source/control')
-rw-r--r--sfx2/source/control/dispatch.cxx23
-rw-r--r--sfx2/source/control/unoctitm.cxx2
2 files changed, 11 insertions, 14 deletions
diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx
index a4db7d7dfc9e..3e9e6d9827f3 100644
--- a/sfx2/source/control/dispatch.cxx
+++ b/sfx2/source/control/dispatch.cxx
@@ -297,7 +297,7 @@ bool SfxDispatcher::IsActive(const SfxShell& rShell)
modal-mode and if the specified slot are handled as frame-specific
(ie, not served by the application).
*/
-bool SfxDispatcher::IsLocked(sal_uInt16) const
+bool SfxDispatcher::IsLocked() const
{
return xImp->bLocked;
}
@@ -890,7 +890,7 @@ void SfxDispatcher::Execute_(SfxShell& rShell, const SfxSlot& rSlot,
DBG_ASSERT( !xImp->bFlushing, "recursive call to dispatcher" );
DBG_ASSERT( xImp->aToDoStack.empty(), "unprepared InPlace _Execute" );
- if ( IsLocked( rSlot.GetSlotId() ) )
+ if ( IsLocked() )
return;
if ( bool(eCallMode & SfxCallMode::ASYNCHRON) ||
@@ -963,7 +963,7 @@ const SfxSlot* SfxDispatcher::GetSlot( const OUString& rCommand )
const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode nCall,
SfxItemSet* pArgs, SfxItemSet* pInternalArgs, sal_uInt16 nModi)
{
- if ( IsLocked(nSlot) )
+ if ( IsLocked() )
return nullptr;
SfxShell *pShell = nullptr;
@@ -1008,7 +1008,7 @@ const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode nCall,
const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
const SfxPoolItem **pArgs, sal_uInt16 nModi, const SfxPoolItem **pInternalArgs)
{
- if ( IsLocked(nSlot) )
+ if ( IsLocked() )
return nullptr;
SfxShell *pShell = nullptr;
@@ -1057,7 +1057,7 @@ const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
const SfxItemSet &rArgs)
{
- if ( IsLocked(nSlot) )
+ if ( IsLocked() )
return nullptr;
SfxShell *pShell = nullptr;
@@ -1108,7 +1108,7 @@ const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
const SfxPoolItem* SfxDispatcher::ExecuteList(sal_uInt16 nSlot, SfxCallMode eCall,
std::initializer_list<SfxPoolItem const*> args)
{
- if ( IsLocked(nSlot) )
+ if ( IsLocked() )
return nullptr;
SfxShell *pShell = nullptr;
@@ -1141,7 +1141,7 @@ IMPL_LINK(SfxDispatcher, PostMsgHandler, SfxRequest*, pReq, void)
// Has also the Pool not yet died?
if ( !pReq->IsCancelled() )
{
- if ( !IsLocked(pReq->GetSlot()) )
+ if ( !IsLocked() )
{
Flush();
SfxSlotServer aSvr;
@@ -1336,7 +1336,6 @@ void SfxDispatcher::Update_Impl_( bool bUIActive, bool bIsMDIApp, bool bIsIPOwne
return;
sal_uInt32 nStatBarId=0;
- SfxShell *pStatusBarShell = nullptr;
SfxSlotPool* pSlotPool = &SfxSlotPool::GetSlotPool( GetFrame() );
sal_uInt16 nTotCount = xImp->aStack.size();
@@ -1435,7 +1434,6 @@ void SfxDispatcher::Update_Impl_( bool bUIActive, bool bIsMDIApp, bool bIsIPOwne
if ( nId )
{
nStatBarId = nId;
- pStatusBarShell = pShell;
}
}
}
@@ -1468,8 +1466,7 @@ void SfxDispatcher::Update_Impl_( bool bUIActive, bool bIsMDIApp, bool bIsIPOwne
if ( bIsTaskActive && nStatBarId && xImp->pFrame )
{
// internal frames also may control statusbar
- SfxBindings& rBindings = xImp->pFrame->GetBindings();
- xImp->pFrame->GetFrame().GetWorkWindow_Impl()->SetStatusBar_Impl( nStatBarId, pStatusBarShell, rBindings );
+ xImp->pFrame->GetFrame().GetWorkWindow_Impl()->SetStatusBar_Impl( nStatBarId );
}
}
}
@@ -1717,7 +1714,7 @@ bool SfxDispatcher::FindServer_(sal_uInt16 nSlot, SfxSlotServer& rServer, bool b
SFX_STACK(SfxDispatcher::FindServer_);
// Dispatcher locked? (nevertheless let SID_HELP_PI through)
- if ( IsLocked(nSlot) )
+ if ( IsLocked() )
{
xImp->bInvalidateOnUnlock = true;
return false;
@@ -1852,7 +1849,7 @@ bool SfxDispatcher::FillState_(const SfxSlotServer& rSvr, SfxItemSet& rState,
SFX_STACK(SfxDispatcher::FillState_);
const SfxSlot *pSlot = rSvr.GetSlot();
- if ( pSlot && IsLocked( pSlot->GetSlotId() ) )
+ if ( pSlot && IsLocked() )
{
xImp->bInvalidateOnUnlock = true;
return false;
diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx
index 98210a528f4b..a4c8ba30d1a7 100644
--- a/sfx2/source/control/unoctitm.cxx
+++ b/sfx2/source/control/unoctitm.cxx
@@ -719,7 +719,7 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const css::util::URL& aURL,
// #i102619# Retrieve metric from shell before execution - the shell could be destroyed after execution
if ( pDispatcher->GetBindings() )
{
- if ( !pDispatcher->IsLocked( GetId() ) )
+ if ( !pDispatcher->IsLocked() )
{
const SfxSlot *pSlot = nullptr;
if ( pDispatcher->GetShellAndSlot_Impl( GetId(), &pShell, &pSlot, false,