diff options
26 files changed, 12 insertions, 425 deletions
diff --git a/sfx2/inc/inettbc.hxx b/sfx2/inc/inettbc.hxx index cbc9e12dad70..6e5b907d4237 100644 --- a/sfx2/inc/inettbc.hxx +++ b/sfx2/inc/inettbc.hxx @@ -77,19 +77,6 @@ public: virtual void StateChanged( USHORT nSID, SfxItemState eState, const SfxPoolItem* pState ); }; -class SfxCancelToolBoxControl_Impl : public SfxToolBoxControl -{ -public: - - SFX_DECL_TOOLBOX_CONTROL(); - - SfxCancelToolBoxControl_Impl( USHORT nSlotId, USHORT nId, ToolBox& rBox ); - - virtual SfxPopupWindowType GetPopupWindowType() const; - virtual SfxPopupWindow* CreatePopupWindow(); - virtual void StateChanged( USHORT nSID, SfxItemState eState, const SfxPoolItem* pState ); -}; - #endif #endif diff --git a/sfx2/inc/sfx2/app.hxx b/sfx2/inc/sfx2/app.hxx index 99deee0c97a3..b770d47e49b5 100644 --- a/sfx2/inc/sfx2/app.hxx +++ b/sfx2/inc/sfx2/app.hxx @@ -61,7 +61,6 @@ class AppSettings; struct SfxChildWinContextFactory; class SfxAppData_Impl; class SfxBindings; -class SfxCancelManager; class SfxChildWinFactArr_Impl; class SfxChildWindow; class SfxDispatcher; @@ -222,7 +221,6 @@ public: // members SfxFilterMatcher& GetFilterMatcher(); - SfxCancelManager* GetCancelManager() const; SfxMacroConfig* GetMacroConfig() const; SfxProgress* GetProgress() const; const String& GetLastSaveDirectory() const; diff --git a/sfx2/inc/sfx2/docfile.hxx b/sfx2/inc/sfx2/docfile.hxx index e8ae3f5d1d85..53712002dbe7 100644 --- a/sfx2/inc/sfx2/docfile.hxx +++ b/sfx2/inc/sfx2/docfile.hxx @@ -51,7 +51,6 @@ #include <svtools/lstner.hxx> #include <tools/globname.hxx> -#include <svtools/cancel.hxx> #include <cppuhelper/weak.hxx> #include <ucbhelper/content.hxx> @@ -67,16 +66,6 @@ class SfxItemSet; class DateTime; class SvStringsDtor; class SvEaMgr; -class SfxPoolCancelManager_Impl; - -#define SFX_TFPRIO_SYNCHRON 0 -#define SFX_TFPRIO_DOC 10 -#define SFX_TFPRIO_VISIBLE_LOWRES_GRAPHIC 20 -#define SFX_TFPRIO_VISIBLE_HIGHRES_GRAPHIC 21 -#define SFX_TFPRIO_PLUGINS 40 -#define SFX_TFPRIO_INVISIBLE_LOWRES_GRAPHIC 50 -#define SFX_TFPRIO_INVISIBLE_HIGHRES_GRAPHIC 51 -#define SFX_TFPRIO_DOWNLOADS 60 #define S2BS(s) ByteString( s, RTL_TEXTENCODING_MS_1252 ) @@ -160,7 +149,6 @@ public: void SetLoadTargetFrame(SfxFrame* pFrame ); SfxFrame* GetLoadTargetFrame() const; - void CancelTransfers(); void SetReferer( const String& rRefer ); const String& GetReferer( ) const; @@ -276,8 +264,6 @@ public: SAL_DLLPRIVATE sal_Bool TransferVersionList_Impl( SfxMedium& rMedium ); SAL_DLLPRIVATE sal_Bool SaveVersionList_Impl( sal_Bool bUseXML ); SAL_DLLPRIVATE sal_Bool RemoveVersion_Impl( const ::rtl::OUString& rVersion ); - SAL_DLLPRIVATE SfxPoolCancelManager_Impl* GetCancelManager_Impl() const; - SAL_DLLPRIVATE void SetCancelManager_Impl( SfxPoolCancelManager_Impl* pMgr ); SAL_DLLPRIVATE void SetExpired_Impl( const DateTime& rDateTime ); SAL_DLLPRIVATE SvKeyValueIterator* GetHeaderAttributes_Impl(); diff --git a/sfx2/inc/sfx2/frame.hxx b/sfx2/inc/sfx2/frame.hxx index 8475907a522d..3d783c80fb6b 100644 --- a/sfx2/inc/sfx2/frame.hxx +++ b/sfx2/inc/sfx2/frame.hxx @@ -86,7 +86,6 @@ class SfxMedium; class SfxFrameHistory_Impl; class SfxDispatcher; class SfxMedium; -class SfxCancellable; class Rectangle; class SfxRequest; class SfxUnoControllerItem; @@ -125,7 +124,6 @@ DECLARE_LIST( TargetList, String* ) //========================================================================== class SfxFrameArr_Impl; -class SfxCancelManager; struct SfxFramePickEntry_Impl; class SfxUnoFrame; class SFX2_DLLPUBLIC SfxFrame @@ -209,7 +207,6 @@ public: const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrameLoader > & rLoader, SfxItemSet* pSet=0, sal_Bool bDontClose=sal_False ); DECL_DLLPRIVATE_STATIC_LINK( SfxFrame, BindingHasNewPart_Impl, void* ); - SAL_DLLPRIVATE SfxCancelManager* GetCancelManager() const; SAL_DLLPRIVATE void GetViewData_Impl(); SAL_DLLPRIVATE void ActivatePickEntry_Impl( SfxFramePickEntry_Impl*, sal_uInt16 nMode, SfxFrameDescriptor *pD = NULL ); SAL_DLLPRIVATE void SetFrameType_Impl( sal_uInt32 ); diff --git a/sfx2/inc/sfx2/viewfrm.hxx b/sfx2/inc/sfx2/viewfrm.hxx index dc0180a19a85..d12e5ca7eabf 100644 --- a/sfx2/inc/sfx2/viewfrm.hxx +++ b/sfx2/inc/sfx2/viewfrm.hxx @@ -51,7 +51,6 @@ class SfxProgress; class SvData; class SfxViewShell; class SvPseudoObject; -class SfxCancelManager; class SystemWindow; class Fraction; class Point; @@ -250,7 +249,6 @@ public: { GetFrame()->GetTargetList( rList ); } void CancelTransfers() { GetFrame()->CancelTransfers(); } - SfxCancelManager* GetCancelManager() const; void SetModalMode( BOOL ); BOOL IsInModalMode() const; diff --git a/sfx2/source/appl/appdata.cxx b/sfx2/source/appl/appdata.cxx index 23de7317c379..e6a1674d5452 100644 --- a/sfx2/source/appl/appdata.cxx +++ b/sfx2/source/appl/appdata.cxx @@ -101,7 +101,6 @@ SfxAppData_Impl::SfxAppData_Impl( SfxApplication* pApp ) : pTopFrames( new SfxFrameArr_Impl ), pInitLinkList(0), pMatcher( 0 ), - pCancelMgr( 0 ), pLabelResMgr( 0 ), pAppDispatch(NULL), pTemplates( 0 ), @@ -152,7 +151,6 @@ SfxAppData_Impl::~SfxAppData_Impl() { DeInitDDE(); delete pTopFrames; - delete pCancelMgr; delete pSecureURLs; delete pBasicManager; diff --git a/sfx2/source/appl/appmisc.cxx b/sfx2/source/appl/appmisc.cxx index 08a61b1f0ce6..e9e0cb386ed8 100644 --- a/sfx2/source/appl/appmisc.cxx +++ b/sfx2/source/appl/appmisc.cxx @@ -329,13 +329,6 @@ ISfxTemplateCommon* SfxApplication::GetCurrentTemplateCommon( SfxBindings& rBind return 0; } -SfxCancelManager* SfxApplication::GetCancelManager() const -{ - if ( !pAppData_Impl->pCancelMgr ) - pAppData_Impl->pCancelMgr = new SfxCancelManager; - return pAppData_Impl->pCancelMgr; -} - SfxResourceManager& SfxApplication::GetResourceManager() const { return *pAppData_Impl->pResMgr; } BOOL SfxApplication::IsDowning() const { return pAppData_Impl->bDowning; } SfxDispatcher* SfxApplication::GetAppDispatcher_Impl() { return pAppData_Impl->pAppDispat; } diff --git a/sfx2/source/appl/appquit.cxx b/sfx2/source/appl/appquit.cxx index 16ae1fe236a9..20836918cbc6 100644 --- a/sfx2/source/appl/appquit.cxx +++ b/sfx2/source/appl/appquit.cxx @@ -119,9 +119,6 @@ BOOL SfxApplication::QueryExit_Impl() } } */ - // alles canceln was zu canceln ist - GetCancelManager()->Cancel(TRUE); - /* SfxObjectShell *pLastDocSh = SfxObjectShell::GetFirst(); if ( bQuit ) diff --git a/sfx2/source/appl/appreg.cxx b/sfx2/source/appl/appreg.cxx index 9e688f885e3c..aa5205f739c4 100644 --- a/sfx2/source/appl/appreg.cxx +++ b/sfx2/source/appl/appreg.cxx @@ -76,7 +76,6 @@ void SfxApplication::Registrations_Impl() // Controller SfxToolBoxControl::RegisterControl(SID_REPEAT); SfxURLToolBoxControl_Impl::RegisterControl(SID_OPENURL); - SfxCancelToolBoxControl_Impl::RegisterControl(SID_BROWSE_STOP); SfxAppToolBoxControl_Impl::RegisterControl( SID_NEWDOCDIRECT ); SfxAppToolBoxControl_Impl::RegisterControl( SID_AUTOPILOTMENU ); }; diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx index 184ecb9f1a5c..24498c19516f 100644 --- a/sfx2/source/appl/appserv.cxx +++ b/sfx2/source/appl/appserv.cxx @@ -71,7 +71,6 @@ #include <tools/config.hxx> #include <tools/diagnose_ex.h> #include <vcl/msgbox.hxx> -#include <svtools/cancel.hxx> #include <svtools/intitem.hxx> #include <svtools/eitem.hxx> #include <svtools/stritem.hxx> diff --git a/sfx2/source/bastyp/progress.cxx b/sfx2/source/bastyp/progress.cxx index 121b8604e02d..97e30932ba25 100644 --- a/sfx2/source/bastyp/progress.cxx +++ b/sfx2/source/bastyp/progress.cxx @@ -80,7 +80,7 @@ void AddNumber_Impl( String& aNumber, sal_uInt32 nArg ) } } -struct SfxProgress_Impl : public SfxCancellable +struct SfxProgress_Impl { Reference < XStatusIndicator > xStatusInd; String aText, aStateText; @@ -144,11 +144,9 @@ void SfxProgress_Impl::Enable_Impl( BOOL bEnable ) // ----------------------------------------------------------------------- -SfxProgress_Impl::SfxProgress_Impl( const String &rTitle ) - : SfxCancellable( SFX_APP()->GetCancelManager(), rTitle ), - pActiveProgress( 0 ) +SfxProgress_Impl::SfxProgress_Impl( const String &/*rTitle*/ ) + : pActiveProgress( 0 ) { - SFX_APP()->GetCancelManager()->RemoveCancellable(this); } // ----------------------------------------------------------------------- @@ -186,21 +184,6 @@ SfxProgress::SfxProgress pImp->bRunning = TRUE; pImp->bAllowRescheduling = Application::IsInExecute();; - if ( pObjSh ) - { - for( SfxViewFrame* pFrame = SfxViewFrame::GetFirst( pObjSh ); pFrame; pFrame = SfxViewFrame::GetNext( *pFrame, pObjSh ) ) - { - pFrame->GetCancelManager()->InsertCancellable( pImp ); -/* - SfxBindings& rBindings = pFrame->GetBindings(); - rBindings.Invalidate( SID_BROWSE_STOP ); - if ( !rBindings.IsInRegistrations() ) - rBindings.Update( SID_BROWSE_STOP ); - rBindings.Invalidate( SID_BROWSE_STOP ); - */ - } - } - pImp->xObjSh = pObjSh; pImp->aText = rText; pImp->nMax = nRange; @@ -242,12 +225,7 @@ SfxProgress::~SfxProgress() if( pImp->bIsStatusText == TRUE ) GetpApp()->HideStatusText( ); SfxObjectShell* pDoc = pImp->xObjSh; - if ( pDoc ) - { - for( SfxViewFrame* pFrame = SfxViewFrame::GetFirst( pDoc ); pFrame; pFrame = SfxViewFrame::GetNext( *pFrame, pDoc ) ) - pFrame->GetCancelManager()->RemoveCancellable( pImp );//Invalidate( SID_BROWSE_STOP ); - } - else + if ( !pDoc ) SFX_APP()->Invalidate( SID_BROWSE_STOP ); delete pImp; } @@ -390,8 +368,8 @@ BOOL SfxProgress::SetState { // wurde via Stop-Button angehalten? - if ( pImp->IsCancelled() ) - return FALSE; +// if ( pImp->IsCancelled() ) +// return FALSE; if( pImp->pActiveProgress ) return TRUE; diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx index 32ae33ec3c8b..c4078dba3118 100644 --- a/sfx2/source/doc/docfile.cxx +++ b/sfx2/source/doc/docfile.cxx @@ -261,79 +261,6 @@ void SAL_CALL SfxMediumHandler_Impl::handle( const com::sun::star::uno::Referenc } //---------------------------------------------------------------- -class SfxPoolCancelManager_Impl : public SfxCancelManager , - public SfxCancellable , - public SfxListener , - public SvRefBase -{ - SfxCancelManagerWeak wParent; - - ~SfxPoolCancelManager_Impl(); -public: - SfxPoolCancelManager_Impl( SfxCancelManager* pParent, const String& rName ); - - virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); - using SfxCancelManager::Cancel; - virtual void Cancel(); -}; - -//---------------------------------------------------------------- -SV_DECL_IMPL_REF( SfxPoolCancelManager_Impl ) - - -//---------------------------------------------------------------- -SfxPoolCancelManager_Impl::SfxPoolCancelManager_Impl( SfxCancelManager* pParent, const String& rName ) - : SfxCancelManager( pParent ), - SfxCancellable( pParent ? pParent : this, rName ), - wParent( pParent ) -{ - if( pParent ) - { - StartListening( *this ); - SetManager( 0 ); - } -} - -//---------------------------------------------------------------- -SfxPoolCancelManager_Impl::~SfxPoolCancelManager_Impl() -{ - for( sal_uInt16 nPos = GetCancellableCount(); nPos--; ) - { - // nicht an Parent uebernehmen! - SfxCancellable* pCbl = GetCancellable( nPos ); - if ( pCbl ) - pCbl->SetManager( 0 ); - } -} - - -//---------------------------------------------------------------- -void SfxPoolCancelManager_Impl::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& /*rHint*/ ) -{ - if( !GetCancellableCount() ) SetManager( 0 ); - else if( !GetManager() ) - { - if( !wParent.Is() ) wParent = SFX_APP()->GetCancelManager(); - SetManager( wParent ); - } -} - -//---------------------------------------------------------------- -void SfxPoolCancelManager_Impl::Cancel() -{ - SfxPoolCancelManager_ImplRef xThis = this; - for( sal_uInt16 nPos = GetCancellableCount(); nPos--; ) - { - SfxCancellable* pCbl = GetCancellable( nPos ); - // Wenn wir nicht im Button stehen - if( pCbl && pCbl != this ) - pCbl->Cancel(); - if( GetCancellableCount() < nPos ) - nPos = GetCancellableCount(); - } -} - -//---------------------------------------------------------------- class SfxMedium_Impl : public SvCompatWeakBase { public: @@ -341,7 +268,6 @@ public: sal_Bool bUpdatePickList : 1; sal_Bool bIsTemp : 1; sal_Bool bForceSynchron : 1; - sal_Bool bDontCreateCancellable : 1; sal_Bool bDownloadDone : 1; sal_Bool bDontCallDoneLinkOnSharingError : 1; sal_Bool bIsStorage: 1; @@ -357,7 +283,6 @@ public: uno::Reference < embed::XStorage > xStorage; - SfxPoolCancelManager_ImplRef xCancelManager; SfxMedium* pAntiImpl; long nFileVersion; @@ -398,8 +323,6 @@ public: uno::Reference< logging::XSimpleLogRing > m_xLogRing; - SfxPoolCancelManager_Impl* GetCancelManager(); - SfxMedium_Impl( SfxMedium* pAntiImplP ); ~SfxMedium_Impl(); }; @@ -415,29 +338,12 @@ void SfxMedium::Cancel_Impl() SetError( ERRCODE_IO_GENERAL, ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ) ); } -SfxPoolCancelManager_Impl* SfxMedium_Impl::GetCancelManager() -{ - if( !xCancelManager.Is() ) - { - if( !bDontCreateCancellable ) - xCancelManager = new SfxPoolCancelManager_Impl( - wLoadTargetFrame ? wLoadTargetFrame->GetCancelManager() : - SFX_APP()->GetCancelManager(), - pAntiImpl->GetURLObject().GetURLNoPass() ); - else - xCancelManager = new SfxPoolCancelManager_Impl( - 0, pAntiImpl->GetURLObject().GetURLNoPass() ); - } - return xCancelManager; -} - //------------------------------------------------------------------ SfxMedium_Impl::SfxMedium_Impl( SfxMedium* pAntiImplP ) : SvCompatWeakBase( pAntiImplP ), bUpdatePickList(sal_True), bIsTemp( sal_False ), bForceSynchron( sal_False ), - bDontCreateCancellable( sal_False ), bDownloadDone( sal_True ), bDontCallDoneLinkOnSharingError( sal_False ), bIsStorage( sal_False ), @@ -2374,25 +2280,7 @@ void SfxMedium::GetMedium_Impl() } } -//------------------------------------------------------------------ -SfxPoolCancelManager_Impl* SfxMedium::GetCancelManager_Impl() const -{ - return pImp->GetCancelManager(); -} - -//------------------------------------------------------------------ -void SfxMedium::SetCancelManager_Impl( SfxPoolCancelManager_Impl* pMgr ) -{ - pImp->xCancelManager = pMgr; -} - //---------------------------------------------------------------- -void SfxMedium::CancelTransfers() -{ - if( pImp->xCancelManager.Is() ) - pImp->xCancelManager->Cancel(); -} - sal_Bool SfxMedium::IsRemote() { return bRemote; @@ -3199,7 +3087,7 @@ sal_Bool SfxMedium::IsDownloadDone_Impl() void SfxMedium::SetDontCreateCancellable( ) { - pImp->bDontCreateCancellable = sal_True; + OSL_ENSURE( false, "SfxMedium::SetDontCreateCancellable: dead code!" ); } ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > SfxMedium::GetInputStream() diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx index 5e3ace93372a..fe0c222c2c92 100644 --- a/sfx2/source/doc/objmisc.cxx +++ b/sfx2/source/doc/objmisc.cxx @@ -1161,7 +1161,6 @@ void SfxObjectShell::RegisterTransfer( SfxMedium& rMedium ) laden, muessen an der zugehoerigen SfxObjectShell angemeldet werden. So kann dokumentweise abgebrochen werden. */ { - rMedium.SetCancelManager_Impl( GetMedium()->GetCancelManager_Impl() ); rMedium.SetReferer( GetMedium()->GetName() ); } @@ -1565,7 +1564,6 @@ void SfxObjectShell::CancelTransfers() Hier koennen Transfers gecanceled werden, die nicht mit RegisterTransfer registiert wurden */ { - GetMedium()->CancelTransfers(); if( ( pImp->nLoadedFlags & SFX_LOADED_ALL ) != SFX_LOADED_ALL ) { AbortImport(); diff --git a/sfx2/source/inc/appdata.hxx b/sfx2/source/inc/appdata.hxx index bd782b76a5ae..696d95501205 100644 --- a/sfx2/source/inc/appdata.hxx +++ b/sfx2/source/inc/appdata.hxx @@ -55,7 +55,6 @@ class SfxFilterMatcher; class SvUShorts; class ISfxTemplateCommon; class SfxFilterMatcher; -class SfxCancelManager; class SfxStatusDispatcher; class SfxDdeTriggerTopic_Impl; class SfxMiscCfg; @@ -112,7 +111,6 @@ public: // application members SfxFilterMatcher* pMatcher; - SfxCancelManager* pCancelMgr; ResMgr* pLabelResMgr; SfxStatusDispatcher* pAppDispatch; SfxDocumentTemplates* pTemplates; diff --git a/sfx2/source/inet/inettbc.cxx b/sfx2/source/inet/inettbc.cxx index d6ce65c96b6d..e9cf246b9919 100644 --- a/sfx2/source/inet/inettbc.cxx +++ b/sfx2/source/inet/inettbc.cxx @@ -42,7 +42,6 @@ #include <com/sun/star/task/XInteractionHandler.hpp> #include <svtools/eitem.hxx> #include <svtools/stritem.hxx> -#include <svtools/cancel.hxx> #include <svtools/historyoptions.hxx> #include <svtools/folderrestriction.hxx> #include <vcl/toolbox.hxx> @@ -305,102 +304,3 @@ void SfxURLToolBoxControl_Impl::StateChanged } } -//*************************************************************************** -// SfxCancelToolBoxControl_Impl -//*************************************************************************** - -SFX_IMPL_TOOLBOX_CONTROL(SfxCancelToolBoxControl_Impl,SfxBoolItem) - -//*************************************************************************** - -SfxCancelToolBoxControl_Impl::SfxCancelToolBoxControl_Impl( USHORT nSlotId, USHORT nId, ToolBox& rBox ) : - SfxToolBoxControl( nSlotId, nId, rBox ) -{ -} - -//*************************************************************************** - -SfxPopupWindowType SfxCancelToolBoxControl_Impl::GetPopupWindowType() const -{ - return SFX_POPUPWINDOW_ONTIMEOUT; -} - -//*************************************************************************** - -SfxPopupWindow* SfxCancelToolBoxControl_Impl::CreatePopupWindow() -{ - PopupMenu aMenu; - BOOL bExecute = FALSE, bSeparator = FALSE; - USHORT nIndex = 1; - for ( SfxCancelManager *pCancelMgr = SfxViewFrame::Current()->GetTopViewFrame()->GetCancelManager(); - pCancelMgr; - pCancelMgr = pCancelMgr->GetParent() ) - { - for ( USHORT n=0; n<pCancelMgr->GetCancellableCount(); ++n ) - { - if ( !n && bSeparator ) - { - aMenu.InsertSeparator(); - bSeparator = FALSE; - } - String aItemText = pCancelMgr->GetCancellable(n)->GetTitle(); - if ( aItemText.Len() > 50 ) - { - aItemText.Erase( 48 ); - aItemText += DEFINE_CONST_UNICODE("..."); - } - aMenu.InsertItem( nIndex++, aItemText ); - bExecute = TRUE; - bSeparator = TRUE; - } - } - - ToolBox& rToolBox = GetToolBox(); - USHORT nId = bExecute ? aMenu.Execute( &rToolBox, rToolBox.GetPointerPosPixel() ) : 0; - GetToolBox().EndSelection(); -// ClearCache(); -// UpdateSlot(); - if ( nId ) - { - String aSearchText = aMenu.GetItemText(nId); - for ( SfxCancelManager *pCancelMgr = SfxViewFrame::Current()->GetTopViewFrame()->GetCancelManager(); - pCancelMgr; - pCancelMgr = pCancelMgr->GetParent() ) - { - for ( USHORT n = 0; n < pCancelMgr->GetCancellableCount(); ++n ) - { - SfxCancellable *pCancel = pCancelMgr->GetCancellable(n); - String aItemText = pCancel->GetTitle(); - if ( aItemText.Len() > 50 ) - { - aItemText.Erase( 48 ); - aItemText += DEFINE_CONST_UNICODE("..."); - } - - if ( aItemText == aSearchText ) - { - pCancel->Cancel(); - return 0; - } - } - } - - } - - return 0; -} - -//*************************************************************************** - -void SfxCancelToolBoxControl_Impl::StateChanged -( - USHORT nSID, - SfxItemState eState, - const SfxPoolItem* pState -) -{ - SfxVoidItem aVoidItem( nSID ); - //SfxToolBoxControl::StateChanged( nSID, eState, pState ? &aVoidItem : 0 ); - SfxToolBoxControl::StateChanged( nSID, eState, pState ); -} - diff --git a/sfx2/source/view/frame.cxx b/sfx2/source/view/frame.cxx index ff8dca80b1e0..04d75a40fda6 100644 --- a/sfx2/source/view/frame.cxx +++ b/sfx2/source/view/frame.cxx @@ -122,18 +122,6 @@ SvCompatWeakHdl* SfxFrame::GetHdl() return pImp->GetHdl(); } -SfxCancelManager* SfxFrame::GetCancelManager() const -{ - SfxFrame *pFrame = GetTopFrame(); - SfxCancelManager*& rpMgr = pFrame->pImp->pCancelMgr; - if ( !rpMgr ) - { - rpMgr = new SfxCancelManager( SFX_APP()->GetCancelManager() ); - pFrame->pImp->StartListening( *rpMgr ); - } - return rpMgr; -} - //-------------------------------------------------------------------- SfxFrame::~SfxFrame() diff --git a/sfx2/source/view/impframe.cxx b/sfx2/source/view/impframe.cxx deleted file mode 100644 index d13beadee9f0..000000000000 --- a/sfx2/source/view/impframe.cxx +++ /dev/null @@ -1,58 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2008 by Sun Microsystems, Inc. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * $RCSfile: impframe.cxx,v $ - * $Revision: 1.9 $ - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * <http://www.openoffice.org/license.html> - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -// MARKER(update_precomp.py): autogen include statement, do not remove -#include "precompiled_sfx2.hxx" - -#ifndef GCC -#endif - -#include "impframe.hxx" - -#include <svtools/smplhint.hxx> - -#include <sfx2/frame.hxx> -#include <sfx2/bindings.hxx> -#include <sfx2/viewfrm.hxx> - -void SfxFrame_Impl::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint ) -{ - SfxSimpleHint* pHint = PTR_CAST( SfxSimpleHint, &rHint ); - if( pHint && pHint->GetId() == SFX_HINT_CANCELLABLE && pCurrentViewFrame ) - { - // vom Cancel-Manager - SfxBindings &rBind = pCurrentViewFrame->GetBindings(); - rBind.Invalidate( SID_BROWSE_STOP ); - if ( !rBind.IsInRegistrations() ) - rBind.Update( SID_BROWSE_STOP ); - rBind.Invalidate( SID_BROWSE_STOP ); - } -} - diff --git a/sfx2/source/view/impframe.hxx b/sfx2/source/view/impframe.hxx index f8233c0c64fe..f5bcc27733b0 100644 --- a/sfx2/source/view/impframe.hxx +++ b/sfx2/source/view/impframe.hxx @@ -31,8 +31,6 @@ #ifndef _SFX_IMPFRAME_HXX #define _SFX_IMPFRAME_HXX -#include <svtools/cancel.hxx> - #include <sfx2/frame.hxx> #include <sfx2/viewfrm.hxx> // SvBorder @@ -54,7 +52,7 @@ class SfxObjectShell; #define FRAME_SEARCH_CREATE 0x00000008 #endif -class SfxFrame_Impl : public SfxBroadcaster, public SvCompatWeakBase, public SfxListener +class SfxFrame_Impl : public SfxBroadcaster, public SvCompatWeakBase { friend class SfxFrame; @@ -74,8 +72,6 @@ friend class SfxFrame; sal_Bool bOwnsBindings : 1; sal_Bool bReleasingComponent : 1; sal_Bool bInPlace : 1; - SfxCancelManager* pCancelMgr; - SfxCancellable* pLoadCancellable; SfxFrame* pFrame; const SfxItemSet* pSet; SfxWorkWindow* pWorkWin; @@ -97,15 +93,12 @@ friend class SfxFrame; bOwnsBindings( sal_False ), bReleasingComponent( sal_False ), bInPlace( sal_False ), - pCancelMgr( 0 ), - pLoadCancellable( 0 ), pFrame( pAntiImplP ), pSet( 0 ), pWorkWin( 0 ) {} - virtual ~SfxFrame_Impl() { delete pCancelMgr; delete pLoadCancellable; } - virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); + virtual ~SfxFrame_Impl() { } }; #endif diff --git a/sfx2/source/view/makefile.mk b/sfx2/source/view/makefile.mk index 98d34215e097..3ab9d5d7e242 100644 --- a/sfx2/source/view/makefile.mk +++ b/sfx2/source/view/makefile.mk @@ -59,7 +59,6 @@ SLOFILES = \ $(SLO)$/viewfac.obj \ $(SLO)$/orgmgr.obj \ $(SLO)$/viewfrm.obj \ - $(SLO)$/impframe.obj \ $(SLO)$/topfrm.obj \ $(SLO)$/sfxbasecontroller.obj \ $(SLO)$/userinputinterception.obj diff --git a/sfx2/source/view/topfrm.cxx b/sfx2/source/view/topfrm.cxx index 5957abb67b27..5508c4a825bf 100644 --- a/sfx2/source/view/topfrm.cxx +++ b/sfx2/source/view/topfrm.cxx @@ -1493,21 +1493,9 @@ void SfxTopViewFrame::INetExecute_Impl( SfxRequest &rRequest ) break; } case SID_BROWSE_STOP: - { - if ( GetCancelManager() ) - GetCancelManager()->Cancel( TRUE ); - - // cancel jobs in hidden tasks - SfxFrameArr_Impl& rArr = *SFX_APP()->Get_Impl()->pTopFrames; - for( USHORT nPos = rArr.Count(); nPos--; ) - { - SfxFrame *pFrame = rArr[ nPos ]; - if ( !pFrame->GetCurrentViewFrame() ) - pFrame->GetCancelManager()->Cancel( TRUE ); - } - + OSL_ENSURE( false, "SID_BROWSE_STOP is dead!" ); break; - } + case SID_FOCUSURLBOX: { SfxStateCache *pCache = GetBindings().GetAnyStateCache_Impl( SID_OPENURL ); @@ -1539,7 +1527,7 @@ void SfxTopViewFrame::INetState_Impl( SfxItemSet &rItemSet ) if ( !pDocSh || bPseudo || bEmbedded || !pDocSh->HasName() ) rItemSet.DisableItem( SID_CREATELINK ); - pImp->pStopButtonTimer->SetButtonState( GetCancelManager()->CanCancel() ); + pImp->pStopButtonTimer->SetButtonState( FALSE ); if ( !pImp->pStopButtonTimer->GetButtonState() ) rItemSet.DisableItem( SID_BROWSE_STOP ); } diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx index abdec58b8ef7..238b2f1100f4 100644 --- a/sfx2/source/view/viewfrm.cxx +++ b/sfx2/source/view/viewfrm.cxx @@ -172,7 +172,6 @@ struct SfxViewFrame_Impl String aActualURL; String aActualPresentationURL; SfxFrame* pFrame; - SfxCancelManager* pCancelMgr; svtools::AsynchronLink* pReloader; //SfxInPlaceFrame* pIPFrame; Window* pWindow; @@ -205,7 +204,6 @@ struct SfxViewFrame_Impl ~SfxViewFrame_Impl() { delete pReloader; - delete pCancelMgr; } }; @@ -1641,7 +1639,6 @@ void SfxViewFrame::Construct_Impl( SfxObjectShell *pObjSh ) pImp->bEnabled = sal_True; pImp->nDocViewNo = 0; pImp->aMargin = Size( -1, -1 ); - pImp->pCancelMgr = 0; pImp->pWindow = 0; SetPool( &SFX_APP()->GetPool() ); @@ -2960,18 +2957,6 @@ SfxViewFrame* SfxViewFrame::GetTopViewFrame() const //------------------------------------------------------------------------- -SfxCancelManager *SfxViewFrame::GetCancelManager() const - -/* <H3>Description</H3> - - Returns a pointer to the <SfxCancelManager> of the top-view-frame of - this view-frame. -*/ - -{ - return GetTopViewFrame()->GetFrame()->GetCancelManager(); -} - void SfxViewFrame::SetWindow_Impl( Window *pWin ) { pImp->pWindow = pWin; diff --git a/svx/inc/linkmgr.hxx b/svx/inc/linkmgr.hxx index b65c91ce7ebd..24a3fff479bb 100644 --- a/svx/inc/linkmgr.hxx +++ b/svx/inc/linkmgr.hxx @@ -79,8 +79,6 @@ public: // (ist zur Zeit nur fuer die FileLinks interressant!) void CancelTransfers(); - static void SetTransferPriority( sfx2::SvBaseLink& rLink, USHORT nPrio ); - // um Status Informationen aus dem FileObject an den BaseLink zu // senden, gibt es eine eigene ClipBoardId. Das SvData-Object hat // dann die entsprechenden Informationen als String. diff --git a/svx/inc/pch/precompiled_svx.hxx b/svx/inc/pch/precompiled_svx.hxx index 8e9bc4d17930..4fe38e521830 100644 --- a/svx/inc/pch/precompiled_svx.hxx +++ b/svx/inc/pch/precompiled_svx.hxx @@ -757,7 +757,6 @@ #include "svtools/apearcfg.hxx" #include "svtools/brdcst.hxx" #include "svtools/cacheoptions.hxx" -#include "svtools/cancel.hxx" #include "svtools/cjkoptions.hxx" #include "svtools/cmdoptions.hxx" #include "svtools/cntwall.hxx" diff --git a/svx/source/svxlink/fileobj.cxx b/svx/source/svxlink/fileobj.cxx index d159c7f78abe..2ccc8754dffc 100644 --- a/svx/source/svxlink/fileobj.cxx +++ b/svx/source/svxlink/fileobj.cxx @@ -692,9 +692,6 @@ BOOL SvFileObject::IsDataComplete() const void SvFileObject::CancelTransfers() { - if( xMed.Is() ) - xMed->CancelTransfers(); - // und aus dem Cache austragen, wenn man mitten im Laden ist if( !bDataReady ) { @@ -706,11 +703,6 @@ void SvFileObject::CancelTransfers() } -void SvFileObject::SetTransferPriority( USHORT ) -{ -} - - void SvFileObject::SendStateChg_Impl( LinkState nState ) { if( !bStateChangeCalled && HasDataLinks() ) diff --git a/svx/source/svxlink/fileobj.hxx b/svx/source/svxlink/fileobj.hxx index 78dbe84dfdc3..44644b1cef0a 100644 --- a/svx/source/svxlink/fileobj.hxx +++ b/svx/source/svxlink/fileobj.hxx @@ -91,7 +91,6 @@ public: virtual BOOL IsDataComplete() const; void CancelTransfers(); - void SetTransferPriority( USHORT nPrio ); }; diff --git a/svx/source/svxlink/linkmgr.cxx b/svx/source/svxlink/linkmgr.cxx index 4f66ba983c06..229632587ba4 100644 --- a/svx/source/svxlink/linkmgr.cxx +++ b/svx/source/svxlink/linkmgr.cxx @@ -181,16 +181,6 @@ void SvxLinkManager::CancelTransfers() pFileObj->CancelTransfers(); } -void SvxLinkManager::SetTransferPriority( sfx2::SvBaseLink& /*rLink*/, USHORT /*nPrio*/ ) -{ -// SvFileObject* pFileObj = -// (SvFileObject*)SvFileObject::ClassFactory()-> -// CastAndAddRef( rLink.GetObj() ); -// OBJECT_CLIENT_FILE == (OBJECT_CLIENT_FILE & rLink.GetObjType()) ? -// (SvFileObject*)rLink.GetObj() : 0; -} - - // um Status Informationen aus dem FileObject an den BaseLink zu // senden, gibt es eine eigene ClipBoardId. Das SvData-Object hat // dann die entsprechenden Informationen als String. |