summaryrefslogtreecommitdiff
path: root/sw/inc/node.hxx
diff options
context:
space:
mode:
authorMichael Stahl <mst@openoffice.org>2010-03-16 11:28:32 +0100
committerMichael Stahl <mst@openoffice.org>2010-03-16 11:28:32 +0100
commita87f73258f3dff9e2c3c91390359d7949c43cbb8 (patch)
tree0e9bca2bb1f2cc3fc648a6e561a50d0571397ac7 /sw/inc/node.hxx
parentd0277b77d53d51972f8d9b0fb09e97289e9e6f56 (diff)
odfmetadata4: #i109599#: make SwSectionNode::pSection member const
Diffstat (limited to 'sw/inc/node.hxx')
-rw-r--r--sw/inc/node.hxx30
1 files changed, 18 insertions, 12 deletions
diff --git a/sw/inc/node.hxx b/sw/inc/node.hxx
index dfff83399b2e..6cc14bbbf2c2 100644
--- a/sw/inc/node.hxx
+++ b/sw/inc/node.hxx
@@ -25,18 +25,23 @@
*
************************************************************************/
-#ifndef _NODE_HXX
-#define _NODE_HXX
+#ifndef SW_NODE_HXX
+#define SW_NODE_HXX
+
+#include <vector>
+
+#include <boost/utility.hpp>
+#include <boost/shared_ptr.hpp>
#include <tools/mempool.hxx>
#include <tools/gen.hxx>
+
#include "swdllapi.h"
#include <ndarr.hxx>
#include <ndtyp.hxx>
#include <index.hxx>
#include <fmtcol.hxx>
-#include <boost/shared_ptr.hpp>
-#include <vector>
+
// ---------------------
// forward Deklarationen
// ---------------------
@@ -548,10 +553,15 @@ private:
//---------
// SwSectionNode
//---------
-class SwSectionNode : public SwStartNode
+class SwSectionNode
+ : public SwStartNode
+ , private ::boost::noncopyable
{
friend class SwNodes;
- SwSection* pSection;
+
+private:
+ ::std::auto_ptr<SwSection> const m_pSection;
+
protected:
virtual ~SwSectionNode();
@@ -559,8 +569,8 @@ public:
SwSectionNode(SwNodeIndex const&,
SwSectionFmt & rFmt, SwTOXBase const*const pTOXBase);
- const SwSection& GetSection() const { return *pSection; }
- SwSection& GetSection() { return *pSection; }
+ const SwSection& GetSection() const { return *m_pSection; }
+ SwSection& GetSection() { return *m_pSection; }
SwFrm *MakeFrm();
@@ -589,10 +599,6 @@ public:
// _nicht_ in einem versteckten (Unter-)Bereich liegt
BOOL IsCntntHidden() const;
-private:
- // privater Constructor, weil nie kopiert werden darf !!
- SwSectionNode( const SwSection& rNode );
- SwSectionNode & operator= ( const SwSection& rNode );
};