diff options
author | Kohei Yoshida <kohei.yoshida@gmail.com> | 2012-04-24 09:28:31 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@gmail.com> | 2012-04-26 09:57:59 -0400 |
commit | 486fa0ba33bab0cbcf42139bfbdd35a4698bad01 (patch) | |
tree | d923d0e19d0e72580ba244ef9f5922326a1d20ee /sc/inc/fielduno.hxx | |
parent | e04892dbb121b3e04e4f432af0bdc0cd7757973c (diff) |
Have the caller pass the content instance directly.
This is to reduce dependency on ScHeaderFooterContentObj from
ScHeaderFieldObj. Eventually that member should be removed and
ScHeaderFieldObj be replaced with ScEditFieldObj.
Diffstat (limited to 'sc/inc/fielduno.hxx')
-rw-r--r-- | sc/inc/fielduno.hxx | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/sc/inc/fielduno.hxx b/sc/inc/fielduno.hxx index d0ce1abf4838..a00dc67b187b 100644 --- a/sc/inc/fielduno.hxx +++ b/sc/inc/fielduno.hxx @@ -340,6 +340,7 @@ class ScHeaderFieldObj : public ScMutexHelper, { private: const SfxItemPropertySet* pPropSet; + com::sun::star::uno::Reference<com::sun::star::text::XTextRange> mpContent; ScHeaderFooterContentObj* pContentObj; sal_uInt16 nPart; sal_uInt16 nType; @@ -349,16 +350,18 @@ private: ScHeaderFieldObj(); // disabled public: - ScHeaderFieldObj(ScHeaderFooterContentObj* pContent, sal_uInt16 nP, - sal_uInt16 nT, const ESelection& rSel); - virtual ~ScHeaderFieldObj(); + ScHeaderFieldObj( + const com::sun::star::uno::Reference<com::sun::star::text::XTextRange>& rContent, + ScHeaderFooterContentObj* pContent, sal_uInt16 nP, sal_uInt16 nT, const ESelection& rSel); + virtual ~ScHeaderFieldObj(); // called by getImplementation: void DeleteField(); sal_Bool IsInserted() const { return pEditSource != NULL; } SvxFieldItem CreateFieldItem(); - void InitDoc( ScHeaderFooterContentObj* pContent, sal_uInt16 nP, - const ESelection& rSel ); + void InitDoc( + const com::sun::star::uno::Reference<com::sun::star::text::XTextRange>& rContent, + ScHeaderFooterContentObj* pContent, sal_uInt16 nP, const ESelection& rSel); virtual ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) |