summaryrefslogtreecommitdiff
path: root/sw/inc/redline.hxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-01-30 15:34:30 +0000
committerCaolán McNamara <caolanm@redhat.com>2015-01-30 17:07:22 +0000
commita5a20187c3a5e5956492f932c49501f9547e4915 (patch)
tree1eb69b1233af1e8d2e7e0f74b3ef7442632a3b46 /sw/inc/redline.hxx
parent75fa61754122cf44a6bd6ac4a0efb44918b1305b (diff)
During DocumentRedlineManager::SetRedlineMode the array becomes unsorted
so GetPos cannot be used safely, so pass down the known index of the redline and propogate it everywhere the redline goes This reverts commit 36e158ce7a0effb130936ba4598a193102faa6a1 Author: Caolán McNamara <caolanm@redhat.com> Date: Mon Jan 19 12:09:17 2015 +0000 if we change the keys we have to resort based on the new keys which tried to keep the table sorted, but thats no use because DocumentRedlineManager::SetRedlineMode loops over by index so sorting the table during the process busts that. Taking a copy of the entries and looping over that shows another gadzillion problems. So try this approach instead. I imagine it should be possible to calculate the correct current index of pRedl in DocumentRedlineManager::AppendRedline but for now assume that we are sorted correctly at that point and can use GetPos Change-Id: If092dce185e3b36fd256db390132358cba155847
Diffstat (limited to 'sw/inc/redline.hxx')
-rw-r--r--sw/inc/redline.hxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/sw/inc/redline.hxx b/sw/inc/redline.hxx
index 17bc9b7896dd..6ff33580bc41 100644
--- a/sw/inc/redline.hxx
+++ b/sw/inc/redline.hxx
@@ -189,8 +189,8 @@ class SW_DLLPUBLIC SwRangeRedline : public SwPaM
void MoveToSection();
void CopyToSection();
- void DelCopyOfSection();
- void MoveFromSection();
+ void DelCopyOfSection(size_t nMyPos);
+ void MoveFromSection(size_t nMyPos);
public:
SwRangeRedline( RedlineType_t eType, const SwPaM& rPam );
@@ -260,10 +260,10 @@ public:
// hide the Del-Redlines via Copy and Delete.
// Otherwise at Move the attribution would be handled incorrectly.
// All other callers must always give 0.
- void CallDisplayFunc( sal_uInt16 nLoop = 0 );
- void Show( sal_uInt16 nLoop = 0 );
- void Hide( sal_uInt16 nLoop = 0 );
- void ShowOriginal( sal_uInt16 nLoop = 0 );
+ void CallDisplayFunc(sal_uInt16 nLoop, size_t nMyPos);
+ void Show(sal_uInt16 nLoop , size_t nMyPos);
+ void Hide(sal_uInt16 nLoop , size_t nMyPos);
+ void ShowOriginal(sal_uInt16 nLoop, size_t nMyPos);
/// Calculates the intersection with text node number nNdIdx.
void CalcStartEnd(sal_uLong nNdIdx, sal_Int32& rStart, sal_Int32& rEnd) const;