diff options
-rw-r--r-- | include/svl/macitem.hxx | 28 | ||||
-rw-r--r-- | svl/source/items/macitem.cxx | 22 |
2 files changed, 2 insertions, 48 deletions
diff --git a/include/svl/macitem.hxx b/include/svl/macitem.hxx index 10f635737b54..85e006e7270f 100644 --- a/include/svl/macitem.hxx +++ b/include/svl/macitem.hxx @@ -47,23 +47,10 @@ enum ScriptType EXTENDED_STYPE }; -// Basisklasse fuer SjJSbxObject mit virtuellem Destruktor -class SjJSbxObjectBase -{ -public: - virtual ~SjJSbxObjectBase(); - virtual SjJSbxObjectBase* Clone( void ); - //virtual SjJSbxObjectBase& operator=( const SjJSbxObjectBase& rBase ); -}; - -class SjJSbxObject; - class SVL_DLLPUBLIC SvxMacro { OUString aMacName; OUString aLibName; - // Fuer JavaScript muss ein Function-Objekt gehalten werden - SjJSbxObjectBase* pFunctionObject; ScriptType eType; public: @@ -73,9 +60,6 @@ public: SvxMacro( const OUString &rMacName, const OUString &rLibName, ScriptType eType); // = STARBASIC entfernt - SvxMacro( SjJSbxObjectBase* _pFunctionObject, const OUString &rSource ); - ~SvxMacro(); // noetig fuer pFunctionObject - const OUString &GetLibName() const { return aLibName; } const OUString &GetMacName() const { return aMacName; } OUString GetLanguage()const; @@ -84,22 +68,12 @@ public: bool HasMacro() const { return !aMacName.isEmpty(); } -#ifdef SOLAR_JAVA - // JavaScript-Function-Objekt holen - // ACHTUNG: Implementation in SJ, Source/JScript/sjimpl.cxx - SjJSbxObjectBase* GetFunctionObject( SjJSbxObject* pParent ); -#endif - SvxMacro& operator=( const SvxMacro& rBase ); }; inline SvxMacro::SvxMacro( const OUString &rMacName, const OUString &rLibName, ScriptType eTyp ) - : aMacName( rMacName ), aLibName( rLibName ), pFunctionObject(NULL), eType( eTyp ) -{} - -inline SvxMacro::SvxMacro( SjJSbxObjectBase* _pFunctionObject, const OUString &rSource ) - : aMacName( rSource ), pFunctionObject( _pFunctionObject ), eType( JAVASCRIPT ) + : aMacName( rMacName ), aLibName( rLibName ), eType( eTyp ) {} //Macro Table, zerstoert die Pointer im DTor! diff --git a/svl/source/items/macitem.cxx b/svl/source/items/macitem.cxx index 66d46d9d92f9..9f17f125a479 100644 --- a/svl/source/items/macitem.cxx +++ b/svl/source/items/macitem.cxx @@ -31,19 +31,9 @@ TYPEINIT1_FACTORY(SvxMacroItem, SfxPoolItem, new SvxMacroItem(0)); // ----------------------------------------------------------------------- - -SjJSbxObjectBase::~SjJSbxObjectBase() -{ -} - -SjJSbxObjectBase* SjJSbxObjectBase::Clone( void ) -{ - return NULL; -} - SvxMacro::SvxMacro( const OUString &rMacName, const OUString &rLanguage) : aMacName( rMacName ), aLibName( rLanguage), - pFunctionObject(NULL), eType( EXTENDED_STYPE) + eType( EXTENDED_STYPE) { if ( rLanguage == SVX_MACRO_LANGUAGE_STARBASIC ) eType=STARBASIC; @@ -51,12 +41,6 @@ SvxMacro::SvxMacro( const OUString &rMacName, const OUString &rLanguage) eType=JAVASCRIPT; } - -SvxMacro::~SvxMacro() -{ - delete pFunctionObject; -} - OUString SvxMacro::GetLanguage()const { if(eType==STARBASIC) @@ -75,16 +59,12 @@ OUString SvxMacro::GetLanguage()const return aLibName; } - - SvxMacro& SvxMacro::operator=( const SvxMacro& rBase ) { if( this != &rBase ) { aMacName = rBase.aMacName; aLibName = rBase.aLibName; - delete pFunctionObject; - pFunctionObject = rBase.pFunctionObject ? rBase.pFunctionObject->Clone() : NULL; eType = rBase.eType; } return *this; |