diff options
-rw-r--r-- | basctl/source/inc/basobj.hxx | 1 | ||||
-rw-r--r-- | sfx2/inc/macro.hxx | 5 | ||||
-rw-r--r-- | sfx2/source/control/macro.cxx | 119 |
3 files changed, 0 insertions, 125 deletions
diff --git a/basctl/source/inc/basobj.hxx b/basctl/source/inc/basobj.hxx index 95d24310e414..e168542c13e4 100644 --- a/basctl/source/inc/basobj.hxx +++ b/basctl/source/inc/basobj.hxx @@ -36,7 +36,6 @@ #include <com/sun/star/script/XLibraryContainer.hpp> #include <com/sun/star/frame/XModel.hpp> -class SfxMacro; class SbMethod; class SbModule; class SbxObject; diff --git a/sfx2/inc/macro.hxx b/sfx2/inc/macro.hxx index 695becf04de6..9b5146fd15df 100644 --- a/sfx2/inc/macro.hxx +++ b/sfx2/inc/macro.hxx @@ -166,11 +166,6 @@ class SfxMacro public: SfxMacro( SfxMacroMode eMode = SFX_MACRO_RECORDINGRELATIVE ); virtual ~SfxMacro(); - - SfxMacroMode GetMode() const; - void Record( SfxMacroStatement *pStatement ); - void Replace( SfxMacroStatement *pStatement ); - void Remove(); }; #endif diff --git a/sfx2/source/control/macro.cxx b/sfx2/source/control/macro.cxx index db6954571e28..26f6abc4c4ab 100644 --- a/sfx2/source/control/macro.cxx +++ b/sfx2/source/control/macro.cxx @@ -398,123 +398,4 @@ SfxMacro::~SfxMacro() //-------------------------------------------------------------------- -SfxMacroMode SfxMacro::GetMode() const - -/* [Description] - - Returns the mode, which indicates for what purpose this SfxMacro was - constructed. - - [Cross-reference] - - enum <SfxMacroMode> -*/ - -{ - return pImp->eMode; -} - -//-------------------------------------------------------------------- - -void SfxMacro::Record -( - SfxMacroStatement* pStatement // the recordning <SfxMacroStatement> -) - -/* [Description] - - This method features the parameters passed on as a Statement. The - instance to which the pointer points is transfered to the ownership - of SfxMacro. - - The call is only valid if it is about a SfxMacro, which was constructed - with SFX_MACRO_RECORDINGRELATIVE or SFX_MACRO_RECORDINGABSOLUTE and is - available as an already recorded statement. - - [Cross-reference] - - <SfxMacro::Replace(SfxMacroStatement*)> - <SfxMacro::Remove()> -*/ - -{ - DBG_ASSERT( pImp->eMode != SFX_MACRO_EXISTING, "invalid call to non-recording SfxMacro" ); - pImp->aList.C40_INSERT( SfxMacroStatement, pStatement, pImp->aList.Count() ); -} - -//-------------------------------------------------------------------- - -void SfxMacro::Replace -( - SfxMacroStatement* pStatement // the recording <SfxMacroStatement> -) - -/* [Description] - - This method records the statement passed on as a parameter. This will - overwrite the last recorded statement. The instance to which the passed - pointer points is transfered to the ownership of the SfxMacro. - - With this method it is possible to combine statements. For example, instead - of calling the 'CursorLeft()' five times could be summarized as - 'CursorLeft (5)'. Or rather than building a word letter by letter, this - could be done by a single statement 'InsertString("Hello")'. - - The call is only valid if it is about a SfxMacro, which was constructed - with SFX_MACRO_RECORDINGRELATIVE or SFX_MACRO_RECORDINGABSOLUTE and is - available as an already recorded statement. - - [Note] - - This method is typically called from the execute methods of - <SfxSlot>s created by the application developers. - - [Cross-reference] - - <SfxMacro::Record(SfxMacroStatement*)> - <SfxMacro::Remove()> -*/ - -{ - DBG_ASSERT( pImp->eMode != SFX_MACRO_EXISTING, "invalid call to non-recording SfxMacro" ); - DBG_ASSERT( pImp->aList.Count(), "no replaceable statement available" ); - pImp->aList.Remove( pImp->aList.Count() - 1 ); - pImp->aList.C40_INSERT( SfxMacroStatement,pStatement, pImp->aList.Count() ); -} - -//-------------------------------------------------------------------- - -void SfxMacro::Remove() - -/* [Description] - - This method deletes the last recorded <SfxMacroStatement> and removes - it from the macro. - - With this method it is possible to combine statements. For example, instead - of calling the 'CursorLeft()' five times could be summarized as - 'CursorLeft (5)'. Or rather than building a word letter by letter, this - could be done by a single statement 'InsertString("Hello")'. - - The call is only valid if it is about a SfxMacro, which was constructed - with SFX_MACRO_RECORDINGRELATIVE or SFX_MACRO_RECORDINGABSOLUTE and is - available as an already recorded statement. - - [Note] - - This method is typically called from the the Execute methods of <SfxSlot>s - by the application developer. - - [Cross-reference] - - <SfxMacro::Replace(SfxMacroStatement*)> - <SfxMacro::Record(SfxMacroStatement*)> -*/ - -{ - DBG_ASSERT( pImp->eMode != SFX_MACRO_EXISTING, "invalid call to non-recording SfxMacro" ); - DBG_ASSERT( pImp->aList.Count(), "no replaceable statement available" ); - pImp->aList.Remove( pImp->aList.Count() - 1 ); -} - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |