[Libreoffice-commits] core.git: 6 commits - solenv/gdb sw/inc sw/source
Michael Stahl
mstahl at redhat.com
Mon Jun 15 12:56:05 PDT 2015
solenv/gdb/libreoffice/sw.py | 4
sw/inc/frmfmt.hxx | 6 +
sw/inc/ndindex.hxx | 124 +++++++++++++-------------
sw/source/core/doc/DocumentRedlineManager.cxx | 2
sw/source/core/doc/docedt.cxx | 8 +
sw/source/core/inc/atrfrm.hxx | 20 ----
sw/source/core/layout/atrfrm.cxx | 6 -
sw/source/filter/ww8/wrtw8esh.cxx | 2
8 files changed, 86 insertions(+), 86 deletions(-)
New commits:
commit 8e36a8fe925abdd39940b8f222e2f381201a6050
Author: Michael Stahl <mstahl at redhat.com>
Date: Mon Jun 15 21:36:58 2015 +0200
sw: move IsFlyFrameFormatInHeader into namespace sw
Change-Id: Ib826ed66ad557bcaba2a7603edc99ad1c6a613f9
diff --git a/sw/inc/frmfmt.hxx b/sw/inc/frmfmt.hxx
index 6d80e23..1e88fa0 100644
--- a/sw/inc/frmfmt.hxx
+++ b/sw/inc/frmfmt.hxx
@@ -300,10 +300,10 @@ public:
DECL_FIXEDMEMPOOL_NEWDEL(SwDrawFrameFormat);
};
-SW_DLLPUBLIC bool IsFlyFrameFormatInHeader(const SwFrameFormat& rFormat);
-
namespace sw {
+SW_DLLPUBLIC bool IsFlyFrameFormatInHeader(const SwFrameFormat& rFormat);
+
void CheckAnchoredFlyConsistency(SwDoc const& rDoc);
}
diff --git a/sw/source/core/layout/atrfrm.cxx b/sw/source/core/layout/atrfrm.cxx
index 42e65b1..fe24b43 100644
--- a/sw/source/core/layout/atrfrm.cxx
+++ b/sw/source/core/layout/atrfrm.cxx
@@ -3463,6 +3463,8 @@ drawinglayer::attribute::SdrAllFillAttributesHelperPtr SwFrameFormat::getSdrAllF
return maFillAttributes;
}
+namespace sw {
+
bool IsFlyFrameFormatInHeader(const SwFrameFormat& rFormat)
{
const SwFlyFrameFormat* pFlyFrameFormat = dynamic_cast<const SwFlyFrameFormat*>(&rFormat);
@@ -3488,8 +3490,6 @@ bool IsFlyFrameFormatInHeader(const SwFrameFormat& rFormat)
return false;
}
-namespace sw {
-
void CheckAnchoredFlyConsistency(SwDoc const& rDoc)
{
#if OSL_DEBUG_LEVEL > 0
diff --git a/sw/source/filter/ww8/wrtw8esh.cxx b/sw/source/filter/ww8/wrtw8esh.cxx
index 7464d10..89aab1e 100644
--- a/sw/source/filter/ww8/wrtw8esh.cxx
+++ b/sw/source/filter/ww8/wrtw8esh.cxx
@@ -2071,7 +2071,7 @@ sal_Int32 SwBasicEscherEx::WriteFlyFrameAttr(const SwFrameFormat& rFormat,
// SwWW8ImplReader::Read_GrafLayer() imports these as opaque
// unconditionally, so if both are true, don't export the property.
- bool bIsInHeader = IsFlyFrameFormatInHeader(rFormat);
+ bool bIsInHeader = sw::IsFlyFrameFormatInHeader(rFormat);
bool bIsThrought = rFormat.GetSurround().GetValue() == SURROUND_THROUGHT;
if (bIsInHeader)
commit aaae5414177560fe40085abc0087ee63d629d5b4
Author: Michael Stahl <mstahl at redhat.com>
Date: Mon Jun 15 21:34:58 2015 +0200
sw: move CheckAnchoredFlyConsistency to frmfmt.hxx
Change-Id: Ic7ccca9e59d2d17ed176d1961aa6f827e404c137
diff --git a/sw/inc/frmfmt.hxx b/sw/inc/frmfmt.hxx
index 2b88acc..6d80e23 100644
--- a/sw/inc/frmfmt.hxx
+++ b/sw/inc/frmfmt.hxx
@@ -302,6 +302,12 @@ public:
SW_DLLPUBLIC bool IsFlyFrameFormatInHeader(const SwFrameFormat& rFormat);
+namespace sw {
+
+void CheckAnchoredFlyConsistency(SwDoc const& rDoc);
+
+}
+
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/core/doc/DocumentRedlineManager.cxx b/sw/source/core/doc/DocumentRedlineManager.cxx
index 1bd8776..610c95f 100644
--- a/sw/source/core/doc/DocumentRedlineManager.cxx
+++ b/sw/source/core/doc/DocumentRedlineManager.cxx
@@ -18,7 +18,7 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
#include <DocumentRedlineManager.hxx>
-#include <atrfrm.hxx>
+#include <frmfmt.hxx>
#include <doc.hxx>
#include <IDocumentUndoRedo.hxx>
#include <IDocumentState.hxx>
diff --git a/sw/source/core/doc/docedt.cxx b/sw/source/core/doc/docedt.cxx
index d4a3161..d0a78cf 100644
--- a/sw/source/core/doc/docedt.cxx
+++ b/sw/source/core/doc/docedt.cxx
@@ -44,7 +44,7 @@
#include <unoflatpara.hxx>
#include <SwGrammarMarkUp.hxx>
#include <docedt.hxx>
-#include <atrfrm.hxx>
+#include <frmfmt.hxx>
#include <vector>
diff --git a/sw/source/core/inc/atrfrm.hxx b/sw/source/core/inc/atrfrm.hxx
deleted file mode 100644
index be59ad6..0000000
--- a/sw/source/core/inc/atrfrm.hxx
+++ /dev/null
@@ -1,20 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#include <sal/config.h>
-
-class SwDoc;
-
-namespace sw {
-
-void CheckAnchoredFlyConsistency(SwDoc const& rDoc);
-
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/core/layout/atrfrm.cxx b/sw/source/core/layout/atrfrm.cxx
index e48f4be..42e65b1 100644
--- a/sw/source/core/layout/atrfrm.cxx
+++ b/sw/source/core/layout/atrfrm.cxx
@@ -24,7 +24,7 @@
#include <svtools/unoimap.hxx>
#include <svtools/imap.hxx>
#include <svtools/imapobj.hxx>
-#include <atrfrm.hxx>
+#include <frmfmt.hxx>
#include <unocoll.hxx>
#include <unosett.hxx>
#include <unostyle.hxx>
commit a624cf52ab08b18b08711567799a08f47c48f89b
Author: Michael Stahl <mstahl at redhat.com>
Date: Mon Jun 15 21:15:54 2015 +0200
sw: fix assert on exporting ooo24533-1.sxw to WW8
There's a fly anchored at a paragraph inside of a table inside of a
redline, and for some reason MoveRange() calls SwTableNode::MakeFrms(),
which asserts in frmtool.cxx AppendObjs().
The problem is that _SaveFlyInRange() removes the frame format from the
SpzFrmFmts but it is still reachable from the SwNode::m_pAnchoredFlys.
Change-Id: I3853c0072662bfb4f71f78451d3604ed567cd584
diff --git a/sw/source/core/doc/docedt.cxx b/sw/source/core/doc/docedt.cxx
index 257b73c..d4a3161 100644
--- a/sw/source/core/doc/docedt.cxx
+++ b/sw/source/core/doc/docedt.cxx
@@ -44,6 +44,7 @@
#include <unoflatpara.hxx>
#include <SwGrammarMarkUp.hxx>
#include <docedt.hxx>
+#include <atrfrm.hxx>
#include <vector>
@@ -77,10 +78,13 @@ void _RestFlyInRange( _SaveFlyArr & rArr, const SwNodeIndex& rSttIdx,
aAnchor.SetAnchor( &aPos );
pFormat->GetDoc()->GetSpzFrameFormats()->push_back( pFormat );
pFormat->SetFormatAttr( aAnchor );
+ // SetFormatAttr will not call Modify() because the node is the same :-/
+ aPos.nNode.GetNode().AddAnchoredFly(pFormat);
SwContentNode* pCNd = aPos.nNode.GetNode().GetContentNode();
if( pCNd && pCNd->getLayoutFrm( pFormat->GetDoc()->getIDocumentLayoutAccess().GetCurrentLayout(), 0, 0, false ) )
pFormat->MakeFrms();
}
+ sw::CheckAnchoredFlyConsistency(*rSttIdx.GetNode().GetDoc());
}
void _SaveFlyInRange( const SwNodeRange& rRg, _SaveFlyArr& rArr )
@@ -100,9 +104,11 @@ void _SaveFlyInRange( const SwNodeRange& rRg, _SaveFlyArr& rArr )
pFormat, false );
rArr.push_back( aSave );
pFormat->DelFrms();
+ pAPos->nNode.GetNode().RemoveAnchoredFly(pFormat);
rFormats.erase( rFormats.begin() + n-- );
}
}
+ sw::CheckAnchoredFlyConsistency(*rRg.aStart.GetNode().GetDoc());
}
void _SaveFlyInRange( const SwPaM& rPam, const SwNodeIndex& rInsPos,
@@ -162,10 +168,12 @@ void _SaveFlyInRange( const SwPaM& rPam, const SwNodeIndex& rInsPos,
pFormat, bInsPos );
rArr.push_back( aSave );
pFormat->DelFrms();
+ pAPos->nNode.GetNode().RemoveAnchoredFly(pFormat);
rFormats.erase( rFormats.begin() + n-- );
}
}
}
+ sw::CheckAnchoredFlyConsistency(*rPam.GetPoint()->nNode.GetNode().GetDoc());
}
/// Delete and move all Flys at the paragraph, that are within the selection.
commit 042dd163a95fa4a128a77f724748b5eb515be8cd
Author: Michael Stahl <mstahl at redhat.com>
Date: Mon Jun 15 18:50:59 2015 +0200
sw: translate that
Change-Id: I08d8941a4c78b5e3307976476fc5c8762732a15c
diff --git a/sw/inc/ndindex.hxx b/sw/inc/ndindex.hxx
index b06bd16..0267e16 100644
--- a/sw/inc/ndindex.hxx
+++ b/sw/inc/ndindex.hxx
@@ -99,12 +99,12 @@ public:
inline bool operator==( const SwNodeIndex& ) const;
inline bool operator!=( const SwNodeIndex& ) const;
- inline bool operator< ( sal_uLong nWert ) const;
- inline bool operator<=( sal_uLong nWert ) const;
- inline bool operator> ( sal_uLong nWert ) const;
- inline bool operator>=( sal_uLong nWert ) const;
- inline bool operator==( sal_uLong nWert ) const;
- inline bool operator!=( sal_uLong nWert ) const;
+ inline bool operator< ( sal_uLong ) const;
+ inline bool operator<=( sal_uLong ) const;
+ inline bool operator> ( sal_uLong ) const;
+ inline bool operator>=( sal_uLong ) const;
+ inline bool operator==( sal_uLong ) const;
+ inline bool operator!=( sal_uLong ) const;
inline SwNodeIndex& operator=( sal_uLong );
inline SwNodeIndex& operator=( const SwNodeIndex& );
@@ -166,29 +166,29 @@ inline SwNodes& SwNodeIndex::GetNodes()
{
return m_pNode->GetNodes();
}
-inline bool SwNodeIndex::operator< ( sal_uLong nWert ) const
+inline bool SwNodeIndex::operator< ( sal_uLong const nOther ) const
{
- return m_pNode->GetIndex() < nWert;
+ return m_pNode->GetIndex() < nOther;
}
-inline bool SwNodeIndex::operator<=( sal_uLong nWert ) const
+inline bool SwNodeIndex::operator<=( sal_uLong const nOther ) const
{
- return m_pNode->GetIndex() <= nWert;
+ return m_pNode->GetIndex() <= nOther;
}
-inline bool SwNodeIndex::operator> ( sal_uLong nWert ) const
+inline bool SwNodeIndex::operator> ( sal_uLong const nOther ) const
{
- return m_pNode->GetIndex() > nWert;
+ return m_pNode->GetIndex() > nOther;
}
-inline bool SwNodeIndex::operator>=( sal_uLong nWert ) const
+inline bool SwNodeIndex::operator>=( sal_uLong const nOther ) const
{
- return m_pNode->GetIndex() >= nWert;
+ return m_pNode->GetIndex() >= nOther;
}
-inline bool SwNodeIndex::operator==( sal_uLong nWert ) const
+inline bool SwNodeIndex::operator==( sal_uLong const nOther ) const
{
- return m_pNode->GetIndex() == nWert;
+ return m_pNode->GetIndex() == nOther;
}
-inline bool SwNodeIndex::operator!=( sal_uLong nWert ) const
+inline bool SwNodeIndex::operator!=( sal_uLong const nOther ) const
{
- return m_pNode->GetIndex() != nWert;
+ return m_pNode->GetIndex() != nOther;
}
inline bool SwNodeIndex::operator<( const SwNodeIndex& rIndex ) const
{
@@ -238,14 +238,14 @@ inline sal_uLong SwNodeIndex::operator--(int)
return nOldIndex;
}
-inline sal_uLong SwNodeIndex::operator+=( sal_uLong nWert )
+inline sal_uLong SwNodeIndex::operator+=( sal_uLong const nOffset )
{
- m_pNode = GetNodes()[ m_pNode->GetIndex() + nWert ];
+ m_pNode = GetNodes()[ m_pNode->GetIndex() + nOffset ];
return m_pNode->GetIndex();
}
-inline sal_uLong SwNodeIndex::operator-=( sal_uLong nWert )
+inline sal_uLong SwNodeIndex::operator-=( sal_uLong const nOffset )
{
- m_pNode = GetNodes()[ m_pNode->GetIndex() - nWert ];
+ m_pNode = GetNodes()[ m_pNode->GetIndex() - nOffset ];
return m_pNode->GetIndex();
}
inline sal_uLong SwNodeIndex::operator+=( const SwNodeIndex& rIndex )
@@ -259,9 +259,9 @@ inline sal_uLong SwNodeIndex::operator-=( const SwNodeIndex& rIndex )
return m_pNode->GetIndex();
}
-inline SwNodeIndex& SwNodeIndex::operator=( sal_uLong nWert )
+inline SwNodeIndex& SwNodeIndex::operator=( sal_uLong const nNew )
{
- m_pNode = GetNodes()[ nWert ];
+ m_pNode = GetNodes()[ nNew ];
return *this;
}
commit ea7d6dc652c58721c3f07cc0c11864404ab48118
Author: Michael Stahl <mstahl at redhat.com>
Date: Mon Jun 15 18:47:52 2015 +0200
sw: deobfuscate a little
Change-Id: I653ed0132f9997164b6bf53e9e6237bfe4fa3fff
diff --git a/sw/inc/ndindex.hxx b/sw/inc/ndindex.hxx
index cd94ff0..b06bd16 100644
--- a/sw/inc/ndindex.hxx
+++ b/sw/inc/ndindex.hxx
@@ -217,11 +217,13 @@ inline bool SwNodeIndex::operator!=( const SwNodeIndex& rIdx ) const
inline sal_uLong SwNodeIndex::operator++()
{
- return ( m_pNode = GetNodes()[ m_pNode->GetIndex()+1 ] )->GetIndex();
+ m_pNode = GetNodes()[ m_pNode->GetIndex()+1 ];
+ return m_pNode->GetIndex();
}
inline sal_uLong SwNodeIndex::operator--()
{
- return ( m_pNode = GetNodes()[ m_pNode->GetIndex()-1 ] )->GetIndex();
+ m_pNode = GetNodes()[ m_pNode->GetIndex()-1 ];
+ return m_pNode->GetIndex();
}
inline sal_uLong SwNodeIndex::operator++(int)
{
@@ -238,19 +240,23 @@ inline sal_uLong SwNodeIndex::operator--(int)
inline sal_uLong SwNodeIndex::operator+=( sal_uLong nWert )
{
- return ( m_pNode = GetNodes()[ m_pNode->GetIndex() + nWert ] )->GetIndex();
+ m_pNode = GetNodes()[ m_pNode->GetIndex() + nWert ];
+ return m_pNode->GetIndex();
}
inline sal_uLong SwNodeIndex::operator-=( sal_uLong nWert )
{
- return ( m_pNode = GetNodes()[ m_pNode->GetIndex() - nWert ] )->GetIndex();
+ m_pNode = GetNodes()[ m_pNode->GetIndex() - nWert ];
+ return m_pNode->GetIndex();
}
inline sal_uLong SwNodeIndex::operator+=( const SwNodeIndex& rIndex )
{
- return ( m_pNode = GetNodes()[ m_pNode->GetIndex() + rIndex.GetIndex() ] )->GetIndex();
+ m_pNode = GetNodes()[ m_pNode->GetIndex() + rIndex.GetIndex() ];
+ return m_pNode->GetIndex();
}
inline sal_uLong SwNodeIndex::operator-=( const SwNodeIndex& rIndex )
{
- return ( m_pNode = GetNodes()[ m_pNode->GetIndex() - rIndex.GetIndex() ] )->GetIndex();
+ m_pNode = GetNodes()[ m_pNode->GetIndex() - rIndex.GetIndex() ];
+ return m_pNode->GetIndex();
}
inline SwNodeIndex& SwNodeIndex::operator=( sal_uLong nWert )
commit 010f1e97a0a53dac09adc3176789b62466a50da3
Author: Michael Stahl <mstahl at redhat.com>
Date: Mon Jun 15 18:41:57 2015 +0200
sw: prefix members of SwNodeIndex
Change-Id: Ia31c7a91bf78b967e70d288374d9e21439c99221
diff --git a/solenv/gdb/libreoffice/sw.py b/solenv/gdb/libreoffice/sw.py
index fa73759..2c5874a 100644
--- a/solenv/gdb/libreoffice/sw.py
+++ b/solenv/gdb/libreoffice/sw.py
@@ -18,7 +18,7 @@ class SwPositionPrinter(object):
self.value = value
def to_string(self):
- node = self.value['nNode']['pNd'].dereference();
+ node = self.value['nNode']['m_pNode'].dereference();
block = node['pBlock'].dereference();
nodeindex = block['nStart'] + node['nOffset']
offset = self.value['nContent']['m_nIndex']
@@ -32,7 +32,7 @@ class SwNodeIndexPrinter(object):
self.value = value
def to_string(self):
- node = self.value['pNd'].dereference();
+ node = self.value['m_pNode'].dereference();
block = node['pBlock'].dereference();
nodeindex = block['nStart'] + node['nOffset']
return "%s (node %d)" % (self.typename, nodeindex)
diff --git a/sw/inc/ndindex.hxx b/sw/inc/ndindex.hxx
index 5223194..cd94ff0 100644
--- a/sw/inc/ndindex.hxx
+++ b/sw/inc/ndindex.hxx
@@ -34,7 +34,7 @@ class SwNodes;
/// Marks a node in the document model.
class SW_DLLPUBLIC SwNodeIndex SAL_FINAL : public sw::Ring<SwNodeIndex>
{
- SwNode* pNd;
+ SwNode * m_pNode;
// These are not allowed!
SwNodeIndex( SwNodes& rNds, sal_uInt16 nIdx ) SAL_DELETED_FUNCTION;
@@ -56,7 +56,7 @@ class SW_DLLPUBLIC SwNodeIndex SAL_FINAL : public sw::Ring<SwNodeIndex>
public:
SwNodeIndex( SwNodes& rNds, sal_uLong nIdx = 0 )
- : pNd( rNds[ nIdx ] )
+ : m_pNode( rNds[ nIdx ] )
{
RegisterIndex( rNds );
};
@@ -64,23 +64,23 @@ public:
: sw::Ring<SwNodeIndex>()
{
if( nDiff )
- pNd = rIdx.GetNodes()[ rIdx.GetIndex() + nDiff ];
+ m_pNode = rIdx.GetNodes()[ rIdx.GetIndex() + nDiff ];
else
- pNd = rIdx.pNd;
- RegisterIndex( pNd->GetNodes() );
+ m_pNode = rIdx.m_pNode;
+ RegisterIndex( m_pNode->GetNodes() );
}
SwNodeIndex( const SwNode& rNd, long nDiff = 0 )
{
if( nDiff )
- pNd = rNd.GetNodes()[ rNd.GetIndex() + nDiff ];
+ m_pNode = rNd.GetNodes()[ rNd.GetIndex() + nDiff ];
else
- pNd = const_cast<SwNode*>(&rNd);
- RegisterIndex( pNd->GetNodes() );
+ m_pNode = const_cast<SwNode*>(&rNd);
+ RegisterIndex( m_pNode->GetNodes() );
}
virtual ~SwNodeIndex()
- { DeRegisterIndex( pNd->GetNodes() ); };
+ { DeRegisterIndex( m_pNode->GetNodes() ); }
inline sal_uLong operator++();
inline sal_uLong operator--();
@@ -121,7 +121,7 @@ public:
inline const SwNodes& GetNodes() const;
inline SwNodes& GetNodes();
- SwNode& GetNode() const { return *pNd; }
+ SwNode& GetNode() const { return *m_pNode; }
};
inline std::ostream &operator <<(std::ostream& s, const SwNodeIndex& index)
@@ -152,129 +152,129 @@ public:
};
// For inlines node.hxx is needed which in turn needs this one.
-// Therefore all inlines accessing pNd are implemented here.
+// Therefore all inlines accessing m_pNode are implemented here.
inline sal_uLong SwNodeIndex::GetIndex() const
{
- return pNd->GetIndex();
+ return m_pNode->GetIndex();
}
inline const SwNodes& SwNodeIndex::GetNodes() const
{
- return pNd->GetNodes();
+ return m_pNode->GetNodes();
}
inline SwNodes& SwNodeIndex::GetNodes()
{
- return pNd->GetNodes();
+ return m_pNode->GetNodes();
}
inline bool SwNodeIndex::operator< ( sal_uLong nWert ) const
{
- return pNd->GetIndex() < nWert;
+ return m_pNode->GetIndex() < nWert;
}
inline bool SwNodeIndex::operator<=( sal_uLong nWert ) const
{
- return pNd->GetIndex() <= nWert;
+ return m_pNode->GetIndex() <= nWert;
}
inline bool SwNodeIndex::operator> ( sal_uLong nWert ) const
{
- return pNd->GetIndex() > nWert;
+ return m_pNode->GetIndex() > nWert;
}
inline bool SwNodeIndex::operator>=( sal_uLong nWert ) const
{
- return pNd->GetIndex() >= nWert;
+ return m_pNode->GetIndex() >= nWert;
}
inline bool SwNodeIndex::operator==( sal_uLong nWert ) const
{
- return pNd->GetIndex() == nWert;
+ return m_pNode->GetIndex() == nWert;
}
inline bool SwNodeIndex::operator!=( sal_uLong nWert ) const
{
- return pNd->GetIndex() != nWert;
+ return m_pNode->GetIndex() != nWert;
}
inline bool SwNodeIndex::operator<( const SwNodeIndex& rIndex ) const
{
- return pNd->GetIndex() < rIndex.GetIndex();
+ return m_pNode->GetIndex() < rIndex.GetIndex();
}
inline bool SwNodeIndex::operator<=( const SwNodeIndex& rIndex ) const
{
- return pNd->GetIndex() <= rIndex.GetIndex();
+ return m_pNode->GetIndex() <= rIndex.GetIndex();
}
inline bool SwNodeIndex::operator>( const SwNodeIndex& rIndex ) const
{
- return pNd->GetIndex() > rIndex.GetIndex();
+ return m_pNode->GetIndex() > rIndex.GetIndex();
}
inline bool SwNodeIndex::operator>=( const SwNodeIndex& rIndex ) const
{
- return pNd->GetIndex() >= rIndex.GetIndex();
+ return m_pNode->GetIndex() >= rIndex.GetIndex();
}
inline bool SwNodeIndex::operator==( const SwNodeIndex& rIdx ) const
{
- return pNd == rIdx.pNd;
+ return m_pNode == rIdx.m_pNode;
}
inline bool SwNodeIndex::operator!=( const SwNodeIndex& rIdx ) const
{
- return pNd != rIdx.pNd;
+ return m_pNode != rIdx.m_pNode;
}
inline sal_uLong SwNodeIndex::operator++()
{
- return ( pNd = GetNodes()[ pNd->GetIndex()+1 ] )->GetIndex();
+ return ( m_pNode = GetNodes()[ m_pNode->GetIndex()+1 ] )->GetIndex();
}
inline sal_uLong SwNodeIndex::operator--()
{
- return ( pNd = GetNodes()[ pNd->GetIndex()-1 ] )->GetIndex();
+ return ( m_pNode = GetNodes()[ m_pNode->GetIndex()-1 ] )->GetIndex();
}
inline sal_uLong SwNodeIndex::operator++(int)
{
- sal_uLong nOldIndex = pNd->GetIndex();
- pNd = GetNodes()[ nOldIndex + 1 ];
+ sal_uLong nOldIndex = m_pNode->GetIndex();
+ m_pNode = GetNodes()[ nOldIndex + 1 ];
return nOldIndex;
}
inline sal_uLong SwNodeIndex::operator--(int)
{
- sal_uLong nOldIndex = pNd->GetIndex();
- pNd = GetNodes()[ nOldIndex - 1 ];
+ sal_uLong nOldIndex = m_pNode->GetIndex();
+ m_pNode = GetNodes()[ nOldIndex - 1 ];
return nOldIndex;
}
inline sal_uLong SwNodeIndex::operator+=( sal_uLong nWert )
{
- return ( pNd = GetNodes()[ pNd->GetIndex() + nWert ] )->GetIndex();
+ return ( m_pNode = GetNodes()[ m_pNode->GetIndex() + nWert ] )->GetIndex();
}
inline sal_uLong SwNodeIndex::operator-=( sal_uLong nWert )
{
- return ( pNd = GetNodes()[ pNd->GetIndex() - nWert ] )->GetIndex();
+ return ( m_pNode = GetNodes()[ m_pNode->GetIndex() - nWert ] )->GetIndex();
}
inline sal_uLong SwNodeIndex::operator+=( const SwNodeIndex& rIndex )
{
- return ( pNd = GetNodes()[ pNd->GetIndex() + rIndex.GetIndex() ] )->GetIndex();
+ return ( m_pNode = GetNodes()[ m_pNode->GetIndex() + rIndex.GetIndex() ] )->GetIndex();
}
inline sal_uLong SwNodeIndex::operator-=( const SwNodeIndex& rIndex )
{
- return ( pNd = GetNodes()[ pNd->GetIndex() - rIndex.GetIndex() ] )->GetIndex();
+ return ( m_pNode = GetNodes()[ m_pNode->GetIndex() - rIndex.GetIndex() ] )->GetIndex();
}
inline SwNodeIndex& SwNodeIndex::operator=( sal_uLong nWert )
{
- pNd = GetNodes()[ nWert ];
+ m_pNode = GetNodes()[ nWert ];
return *this;
}
SwNodeIndex& SwNodeIndex::operator=( const SwNodeIndex& rIdx )
{
- *this = *(rIdx.pNd);
+ *this = *(rIdx.m_pNode);
return *this;
}
SwNodeIndex& SwNodeIndex::operator=( const SwNode& rNd )
{
- if( &pNd->GetNodes() != &rNd.GetNodes() )
+ if (&m_pNode->GetNodes() != &rNd.GetNodes())
{
- DeRegisterIndex( pNd->GetNodes() );
- pNd = const_cast<SwNode*>(&rNd);
- RegisterIndex( pNd->GetNodes() );
+ DeRegisterIndex( m_pNode->GetNodes() );
+ m_pNode = const_cast<SwNode*>(&rNd);
+ RegisterIndex( m_pNode->GetNodes() );
}
else
- pNd = const_cast<SwNode*>(&rNd);
+ m_pNode = const_cast<SwNode*>(&rNd);
return *this;
}
@@ -289,7 +289,7 @@ SwNodeIndex& SwNodeIndex::Assign( const SwNode& rNd, long nOffset )
*this = rNd;
if( nOffset )
- pNd = pNd->GetNodes()[ pNd->GetIndex() + nOffset ];
+ m_pNode = m_pNode->GetNodes()[ m_pNode->GetIndex() + nOffset ];
return *this;
}
More information about the Libreoffice-commits
mailing list