summaryrefslogtreecommitdiff
path: root/sc/inc/textuno.hxx
diff options
context:
space:
mode:
authorNiklas Nebel <nn@openoffice.org>2001-07-31 16:57:55 +0000
committerNiklas Nebel <nn@openoffice.org>2001-07-31 16:57:55 +0000
commit369e3b02e6063d78031a5f4e4b5d9ef36d3f92f5 (patch)
tree14ae0cb46165f26a55d574396f4c61118c5e40bd /sc/inc/textuno.hxx
parent8e5874c8845461a9f7f66476e7d1932d92925ade (diff)
#90142# share data for text in page headers / footers
Diffstat (limited to 'sc/inc/textuno.hxx')
-rw-r--r--sc/inc/textuno.hxx39
1 files changed, 34 insertions, 5 deletions
diff --git a/sc/inc/textuno.hxx b/sc/inc/textuno.hxx
index 541efebe13dd..6b1c8b865005 100644
--- a/sc/inc/textuno.hxx
+++ b/sc/inc/textuno.hxx
@@ -2,9 +2,9 @@
*
* $RCSfile: textuno.hxx,v $
*
- * $Revision: 1.6 $
+ * $Revision: 1.7 $
*
- * last change: $Author: sab $ $Date: 2001-06-13 17:01:24 $
+ * last change: $Author: nn $ $Date: 2001-07-31 17:56:45 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -174,6 +174,34 @@ public:
};
+// ScHeaderFooterTextData: shared data between sub objects of a ScHeaderFooterTextObj
+
+class ScHeaderFooterTextData : public SfxListener
+{
+private:
+ ScHeaderFooterContentObj& rContentObj;
+ USHORT nPart;
+ ScEditEngineDefaulter* pEditEngine;
+ SvxEditEngineForwarder* pForwarder;
+ BOOL bDataValid;
+ BOOL bInUpdate;
+
+public:
+ ScHeaderFooterTextData( ScHeaderFooterContentObj& rContent,
+ USHORT nP );
+ ~ScHeaderFooterTextData();
+
+ virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
+
+ // helper functions
+ SvxTextForwarder* GetTextForwarder();
+ void UpdateData();
+ ScEditEngineDefaulter* GetEditEngine() { GetTextForwarder(); return pEditEngine; }
+
+ USHORT GetPart() const { return nPart; }
+ ScHeaderFooterContentObj& GetContentObj() const { return rContentObj; }
+};
+
// ScHeaderFooterTextObj veraendert den Text in einem ScHeaderFooterContentObj
class ScHeaderFooterTextObj : public cppu::WeakImplHelper5<
@@ -184,16 +212,17 @@ class ScHeaderFooterTextObj : public cppu::WeakImplHelper5<
com::sun::star::lang::XServiceInfo >
{
private:
- ScHeaderFooterContentObj& rContentObj;
- USHORT nPart;
+ ScHeaderFooterTextData aTextData;
SvxUnoText* pUnoText;
+ void CreateUnoText_Impl();
+
public:
ScHeaderFooterTextObj( ScHeaderFooterContentObj& rContent,
USHORT nP );
virtual ~ScHeaderFooterTextObj();
- const SvxUnoText& GetUnoText() const;
+ const SvxUnoText& GetUnoText();
static void FillDummyFieldData( ScHeaderFieldData& rData );