summaryrefslogtreecommitdiff
path: root/vbahelper/inc
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2012-03-24 14:00:06 +0000
committerCaolán McNamara <caolanm@redhat.com>2012-03-26 12:18:08 +0100
commitd41b5a88bd4fdff79975d0a64a56d6aae2be1f22 (patch)
tree79f755f5f8bdc4d4e9485e6afe2c12fac168413f /vbahelper/inc
parent35fe7d4365f0fd9e118d17bb4b579cf303cd6720 (diff)
reduce over use of static OUStrings
Diffstat (limited to 'vbahelper/inc')
-rw-r--r--vbahelper/inc/vbahelper/vbaapplicationbase.hxx2
-rw-r--r--vbahelper/inc/vbahelper/vbadocumentbase.hxx2
-rw-r--r--vbahelper/inc/vbahelper/vbahelperinterface.hxx9
-rw-r--r--vbahelper/inc/vbahelper/vbashape.hxx2
-rw-r--r--vbahelper/inc/vbahelper/vbashaperange.hxx2
-rw-r--r--vbahelper/inc/vbahelper/vbashapes.hxx2
-rw-r--r--vbahelper/inc/vbahelper/vbatextframe.hxx2
-rw-r--r--vbahelper/inc/vbahelper/vbawindowbase.hxx2
8 files changed, 11 insertions, 12 deletions
diff --git a/vbahelper/inc/vbahelper/vbaapplicationbase.hxx b/vbahelper/inc/vbahelper/vbaapplicationbase.hxx
index a27afa5d5b01..ed42d577c260 100644
--- a/vbahelper/inc/vbahelper/vbaapplicationbase.hxx
+++ b/vbahelper/inc/vbahelper/vbaapplicationbase.hxx
@@ -70,7 +70,7 @@ public:
virtual void SAL_CALL Quit() throw (css::uno::RuntimeException);
// XHelperInterface
- virtual rtl::OUString& getServiceImplName();
+ virtual rtl::OUString getServiceImplName();
virtual css::uno::Sequence<rtl::OUString> getServiceNames();
};
#endif
diff --git a/vbahelper/inc/vbahelper/vbadocumentbase.hxx b/vbahelper/inc/vbahelper/vbadocumentbase.hxx
index d2c1a1ad7e29..79d71f060220 100644
--- a/vbahelper/inc/vbahelper/vbadocumentbase.hxx
+++ b/vbahelper/inc/vbahelper/vbadocumentbase.hxx
@@ -66,7 +66,7 @@ public:
virtual void SAL_CALL Activate() throw (css::uno::RuntimeException);
// XHelperInterface
- virtual rtl::OUString& getServiceImplName();
+ virtual rtl::OUString getServiceImplName();
virtual css::uno::Sequence<rtl::OUString> getServiceNames();
};
diff --git a/vbahelper/inc/vbahelper/vbahelperinterface.hxx b/vbahelper/inc/vbahelper/vbahelperinterface.hxx
index 02d9f348a6bf..7e4875ff0b52 100644
--- a/vbahelper/inc/vbahelper/vbahelperinterface.hxx
+++ b/vbahelper/inc/vbahelper/vbahelperinterface.hxx
@@ -73,7 +73,7 @@ public:
InheritedHelperInterfaceImpl() {}
InheritedHelperInterfaceImpl( const css::uno::Reference< css::uno::XComponentContext >& xContext ) : mxContext( xContext ) {}
InheritedHelperInterfaceImpl( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext ) : mxParent( xParent ), mxContext( xContext ) {}
- virtual rtl::OUString& getServiceImplName() = 0;
+ virtual rtl::OUString getServiceImplName() = 0;
virtual css::uno::Sequence<rtl::OUString> getServiceNames() = 0;
// XHelperInterface Methods
@@ -146,10 +146,9 @@ public:
implementation name.
*/
#define VBAHELPER_IMPL_GETSERVICEIMPLNAME( classname ) \
-::rtl::OUString& classname::getServiceImplName() \
+::rtl::OUString classname::getServiceImplName() \
{ \
- static ::rtl::OUString saImplName = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( #classname ) ); \
- return saImplName; \
+ return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( #classname ) ); \
}
// ----------------------------------------------------------------------------
@@ -176,7 +175,7 @@ css::uno::Sequence< ::rtl::OUString > classname::getServiceNames() \
declaration.
*/
#define VBAHELPER_DECL_XHELPERINTERFACE \
- virtual ::rtl::OUString& getServiceImplName(); \
+ virtual ::rtl::OUString getServiceImplName(); \
virtual css::uno::Sequence< ::rtl::OUString > getServiceNames();
// ----------------------------------------------------------------------------
diff --git a/vbahelper/inc/vbahelper/vbashape.hxx b/vbahelper/inc/vbahelper/vbashape.hxx
index 60f77769c7b4..12ffd6afa9b0 100644
--- a/vbahelper/inc/vbahelper/vbashape.hxx
+++ b/vbahelper/inc/vbahelper/vbashape.hxx
@@ -58,7 +58,7 @@ protected:
virtual void addListeners();
virtual void removeShapeListener() throw( css::uno::RuntimeException );
virtual void removeShapesListener() throw( css::uno::RuntimeException );
- virtual rtl::OUString& getServiceImplName();
+ virtual rtl::OUString getServiceImplName();
virtual css::uno::Sequence<rtl::OUString> getServiceNames();
public:
ScVbaShape( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const css::uno::Reference< css::drawing::XShape >& xShape, const css::uno::Reference< css::drawing::XShapes >& xShapes, const css::uno::Reference< css::frame::XModel >& xModel, sal_Int32 nType ) throw ( css::lang::IllegalArgumentException );
diff --git a/vbahelper/inc/vbahelper/vbashaperange.hxx b/vbahelper/inc/vbahelper/vbashaperange.hxx
index 7a580dac5e77..851b7f28cdf1 100644
--- a/vbahelper/inc/vbahelper/vbashaperange.hxx
+++ b/vbahelper/inc/vbahelper/vbashaperange.hxx
@@ -45,7 +45,7 @@ private:
sal_Int32 m_nShapeGroupCount;
protected:
css::uno::Reference< css::frame::XModel > m_xModel;
- virtual rtl::OUString& getServiceImplName();
+ virtual rtl::OUString getServiceImplName();
virtual css::uno::Sequence<rtl::OUString> getServiceNames();
css::uno::Reference< css::drawing::XShapes > getShapes() throw (css::uno::RuntimeException) ;
public:
diff --git a/vbahelper/inc/vbahelper/vbashapes.hxx b/vbahelper/inc/vbahelper/vbashapes.hxx
index ef35d2c6b827..5c2582829630 100644
--- a/vbahelper/inc/vbahelper/vbashapes.hxx
+++ b/vbahelper/inc/vbahelper/vbashapes.hxx
@@ -48,7 +48,7 @@ private:
void initBaseCollection();
protected:
css::uno::Reference< css::frame::XModel > m_xModel;
- virtual rtl::OUString& getServiceImplName();
+ virtual rtl::OUString getServiceImplName();
virtual css::uno::Sequence<rtl::OUString> getServiceNames();
virtual css::uno::Reference< css::container::XIndexAccess > getShapesByArrayIndices( const css::uno::Any& Index ) throw (css::uno::RuntimeException);
css::uno::Reference< css::drawing::XShape > createShape( rtl::OUString service ) throw (css::uno::RuntimeException);
diff --git a/vbahelper/inc/vbahelper/vbatextframe.hxx b/vbahelper/inc/vbahelper/vbatextframe.hxx
index 584e2559315c..e4d0dc98163c 100644
--- a/vbahelper/inc/vbahelper/vbatextframe.hxx
+++ b/vbahelper/inc/vbahelper/vbatextframe.hxx
@@ -40,7 +40,7 @@ protected:
css::uno::Reference< css::drawing::XShape > m_xShape;
css::uno::Reference< css::beans::XPropertySet > m_xPropertySet;
protected:
- virtual rtl::OUString& getServiceImplName();
+ virtual rtl::OUString getServiceImplName();
virtual css::uno::Sequence<rtl::OUString> getServiceNames();
virtual void setAsMSObehavior();
sal_Int32 getMargin( rtl::OUString sMarginType );
diff --git a/vbahelper/inc/vbahelper/vbawindowbase.hxx b/vbahelper/inc/vbahelper/vbawindowbase.hxx
index 40119b4ea7a3..dc6efb04cf49 100644
--- a/vbahelper/inc/vbahelper/vbawindowbase.hxx
+++ b/vbahelper/inc/vbahelper/vbawindowbase.hxx
@@ -63,7 +63,7 @@ public:
virtual void SAL_CALL setWidth( sal_Int32 _width ) throw (css::uno::RuntimeException) ;
// XHelperInterface
- virtual rtl::OUString& getServiceImplName();
+ virtual rtl::OUString getServiceImplName();
virtual css::uno::Sequence<rtl::OUString> getServiceNames();
protected: