Kaydet (Commit) d3c77222 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Use rtl::Reference<>.

üst ca6052b9
...@@ -49,6 +49,7 @@ ...@@ -49,6 +49,7 @@
#include <cppuhelper/implbase3.hxx> #include <cppuhelper/implbase3.hxx>
#include <cppuhelper/implbase5.hxx> #include <cppuhelper/implbase5.hxx>
#include <cppuhelper/implbase6.hxx> #include <cppuhelper/implbase6.hxx>
#include <rtl/ref.hxx>
class ScDocShell; class ScDocShell;
class ScRangeName; class ScRangeName;
...@@ -67,7 +68,7 @@ class ScNamedRangeObj : public ::cppu::WeakImplHelper6< ...@@ -67,7 +68,7 @@ class ScNamedRangeObj : public ::cppu::WeakImplHelper6<
public SfxListener public SfxListener
{ {
private: private:
com::sun::star::uno::Reference< com::sun::star::sheet::XNamedRanges > mxParent; rtl::Reference< ScNamedRangesObj > mxParent;
ScDocShell* pDocShell; ScDocShell* pDocShell;
String aName; String aName;
com::sun::star::uno::Reference< com::sun::star::container::XNamed > mxSheet; com::sun::star::uno::Reference< com::sun::star::container::XNamed > mxSheet;
...@@ -81,7 +82,7 @@ private: ...@@ -81,7 +82,7 @@ private:
SCTAB GetTab_Impl(); SCTAB GetTab_Impl();
public: public:
ScNamedRangeObj( com::sun::star::uno::Reference< com::sun::star::sheet::XNamedRanges > xParent, ScDocShell* pDocSh, const String& rNm, ScNamedRangeObj( rtl::Reference< ScNamedRangesObj > xParent, ScDocShell* pDocSh, const String& rNm,
com::sun::star::uno::Reference< com::sun::star::container::XNamed > xSheet = com::sun::star::uno::Reference< com::sun::star::container::XNamed > ()); com::sun::star::uno::Reference< com::sun::star::container::XNamed > xSheet = com::sun::star::uno::Reference< com::sun::star::container::XNamed > ());
virtual ~ScNamedRangeObj(); virtual ~ScNamedRangeObj();
......
...@@ -97,7 +97,7 @@ bool lcl_UserVisibleName(const ScRangeData& rData) ...@@ -97,7 +97,7 @@ bool lcl_UserVisibleName(const ScRangeData& rData)
return !rData.HasType(RT_DATABASE) && !rData.HasType(RT_SHARED); return !rData.HasType(RT_DATABASE) && !rData.HasType(RT_SHARED);
} }
ScNamedRangeObj::ScNamedRangeObj( Reference< sheet::XNamedRanges > xParent, ScDocShell* pDocSh, const String& rNm, Reference<container::XNamed> xSheet): ScNamedRangeObj::ScNamedRangeObj( rtl::Reference< ScNamedRangesObj > xParent, ScDocShell* pDocSh, const String& rNm, Reference<container::XNamed> xSheet):
mxParent(xParent), mxParent(xParent),
pDocShell( pDocSh ), pDocShell( pDocSh ),
aName( rNm ), aName( rNm ),
...@@ -213,7 +213,7 @@ void ScNamedRangeObj::Modify_Impl( const String* pNewName, const ScTokenArray* p ...@@ -213,7 +213,7 @@ void ScNamedRangeObj::Modify_Impl( const String* pNewName, const ScTokenArray* p
if (pNewRanges->insert(pNew)) if (pNewRanges->insert(pNew))
{ {
ScDocFunc aFunc(*pDocShell); ScDocFunc aFunc(*pDocShell);
aFunc.SetNewRangeNames(pNewRanges, dynamic_cast<ScNamedRangesObj*>(mxParent.get())->IsModifyAndBroadcast(), nTab); aFunc.SetNewRangeNames(pNewRanges, mxParent->IsModifyAndBroadcast(), nTab);
aName = aInsName; //! broadcast? aName = aInsName; //! broadcast?
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment