diff options
author | Noel Grandin <noel@peralex.com> | 2015-03-02 13:50:43 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-03-19 10:45:00 +0200 |
commit | 5133b27e638140ba574016b33dae70ca92edc323 (patch) | |
tree | 8c113b072c017a2beb6b96fa144c7ccb399373f5 /sfx2/source/control | |
parent | 062e40c76bcab664907737feace74f134a25c29c (diff) |
loplugin:constantfunction: sfx2
Change-Id: I7b4c18b1f9644048f506fc1b1d1fb8c8c590ea7f
Diffstat (limited to 'sfx2/source/control')
-rw-r--r-- | sfx2/source/control/bindings.cxx | 5 | ||||
-rw-r--r-- | sfx2/source/control/ctrlitem.cxx | 6 | ||||
-rw-r--r-- | sfx2/source/control/dispatch.cxx | 21 | ||||
-rw-r--r-- | sfx2/source/control/shell.cxx | 12 | ||||
-rw-r--r-- | sfx2/source/control/statcach.cxx | 13 | ||||
-rw-r--r-- | sfx2/source/control/unoctitm.cxx | 19 |
6 files changed, 1 insertions, 75 deletions
diff --git a/sfx2/source/control/bindings.cxx b/sfx2/source/control/bindings.cxx index 9b22f4e7857e..b002aabcefb6 100644 --- a/sfx2/source/control/bindings.cxx +++ b/sfx2/source/control/bindings.cxx @@ -300,9 +300,6 @@ void SfxBindings::DeleteControllers_Impl() SfxStateCache *pCache = (*pImp->pCaches)[nCache]; sal_uInt16 nSlotId = pCache->GetId(); - // Delete SfxPopupWindow - pCache->DeleteFloatingWindows(); - // Re-align, because the cache may have been reduced sal_uInt16 nNewCount = pImp->pCaches->size(); if ( nNewCount < nCount ) @@ -385,8 +382,6 @@ void SfxBindings::HidePopupCtrls_Impl( bool bHide ) pImp->ePopupAction = SFX_POPUP_SHOW; } - for(SfxStateCacheArr_Impl::const_iterator it = pImp->pCaches->begin(); it != pImp->pCaches->end(); ++it) - (*it)->DeleteFloatingWindows(); pImp->ePopupAction = SFX_POPUP_DELETE; } diff --git a/sfx2/source/control/ctrlitem.cxx b/sfx2/source/control/ctrlitem.cxx index c602e443b457..c1fa1624daa5 100644 --- a/sfx2/source/control/ctrlitem.cxx +++ b/sfx2/source/control/ctrlitem.cxx @@ -260,12 +260,6 @@ void SfxControllerItem::StateChanged -void SfxControllerItem::DeleteFloatingWindow() -{ -} - - - void SfxStatusForwarder::StateChanged ( sal_uInt16 nSID, // <SID> of the triggering slot diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx index 16cca9d30ea2..bf6e77f738f7 100644 --- a/sfx2/source/control/dispatch.cxx +++ b/sfx2/source/control/dispatch.cxx @@ -692,8 +692,6 @@ void SfxDispatcher::DoActivate_Impl(bool bMDI, SfxViewFrame* /* pOld */) void SfxDispatcher::DoParentActivate_Impl() { - for ( int i = int(xImp->aStack.size()) - 1; i >= 0; --i ) - (*(xImp->aStack.rbegin() + i ))->ParentActivate(); } /** This method controls the deactivation of a dispatcher. @@ -775,8 +773,6 @@ void SfxDispatcher::DoDeactivate_Impl(bool bMDI, SfxViewFrame* pNew) void SfxDispatcher::DoParentDeactivate_Impl() { - for ( int i = int(xImp->aStack.size()) - 1; i >= 0; --i ) - (*(xImp->aStack.rbegin() + i))->ParentDeactivate(); } /** This method searches in SfxDispatcher after <SfxShell> , from the Slot Id @@ -1658,22 +1654,7 @@ bool SfxDispatcher::_TryIntercept_Impl sal_uInt16 nLevels = xImp->aStack.size(); while ( pParent && pParent->xImp->pFrame ) { - if ( pParent->xImp->pFrame->GetFrame().HasComponent() ) - { - // Components may be intercepted - if ( pParent->_TryIntercept_Impl( nSlot, rServer, true ) ) - { - // The own shells are added to the Shell Level - rServer.SetShellLevel( rServer.GetShellLevel() + nLevels ); - return true; - } - else - // No further Interception - break; - } - else - nLevels = nLevels + pParent->xImp->aStack.size(); - + nLevels = nLevels + pParent->xImp->aStack.size(); pParent = pParent->xImp->pParent; } diff --git a/sfx2/source/control/shell.cxx b/sfx2/source/control/shell.cxx index 3d28d8045396..b055444c1808 100644 --- a/sfx2/source/control/shell.cxx +++ b/sfx2/source/control/shell.cxx @@ -395,18 +395,6 @@ void SfxShell::Deactivate BroadcastContextForActivation(false); } -void SfxShell::ParentActivate -( -) -{ -} - -void SfxShell::ParentDeactivate -( -) -{ -} - bool SfxShell::CanExecuteSlot_Impl( const SfxSlot &rSlot ) { // Get Slot status diff --git a/sfx2/source/control/statcach.cxx b/sfx2/source/control/statcach.cxx index 9a679e66853a..553cf4a1b645 100644 --- a/sfx2/source/control/statcach.cxx +++ b/sfx2/source/control/statcach.cxx @@ -478,19 +478,6 @@ void SfxStateCache::SetCachedState( bool bAlways ) -// Destroy FloatingWindows in all Controls with this Id - -void SfxStateCache::DeleteFloatingWindows() -{ - - SfxControllerItem *pNextCtrl=0; - for ( SfxControllerItem *pCtrl=pController; pCtrl; pCtrl=pNextCtrl ) - { - pNextCtrl = pCtrl->GetItemLink(); - pCtrl->DeleteFloatingWindow(); - } -} - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > SfxStateCache::GetDispatch() const { if ( pDispatch ) diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index 45bd65e95774..d355efacaba5 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -241,16 +241,6 @@ void SfxUnoControllerItem::GetNewDispatch() // parent may intercept xDisp = TryGetDispatch( pParent ); - // only components may intercept - if ( !xDisp.is() && pFrame->HasComponent() ) - { - // no interception - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > xFrame = pFrame->GetFrameInterface(); - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatchProvider > xProv( xFrame, ::com::sun::star::uno::UNO_QUERY ); - if ( xProv.is() ) - xDisp = xProv->queryDispatch( aCommand, OUString(), 0 ); - } - return xDisp; } @@ -611,7 +601,6 @@ class UsageInfo { public: UsageInfo() { - load(); } ~UsageInfo() @@ -622,9 +611,6 @@ public: /// Increment command's use. void increment(const OUString &rCommand); - /// Load the usage data from the previous session. - void load(); - /// Save the usage data for the next session. void save(); }; @@ -639,11 +625,6 @@ void UsageInfo::increment(const OUString &rCommand) maUsage[rCommand] = 1; } -void UsageInfo::load() -{ - // TODO - do the real loading here -} - void UsageInfo::save() { if (!officecfg::Office::Common::Misc::CollectUsageInformation::get()) |