summaryrefslogtreecommitdiff
path: root/sw/source/core
diff options
context:
space:
mode:
authorTamás Zolnai <tamas.zolnai@collabora.com>2018-01-14 00:16:26 +0100
committerAndras Timar <andras.timar@collabora.com>2018-03-15 23:03:47 +0100
commitcb8633eed7569cd8d137649758d1ede204f249e1 (patch)
tree5faae337cfa766f2178ba9391f2f492ed3648775 /sw/source/core
parent70df28bca289cd3716b00638a03d4d860c3514ad (diff)
lok: Tile not invalidated with certain changes
Calling FillRects caused this issue, which updates text area, so the invalidation, runing after that call, won't now where was the old text. We call invalidation here on the whole frame not only on the rects where the actual text is. Change-Id: I23db4b9579aa5710540b5d241506726630219b02 Reviewed-on: https://gerrit.libreoffice.org/47848 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit 39dd42b5aa34d0960cdab0c9fd967d4ae5cc6801)
Diffstat (limited to 'sw/source/core')
-rw-r--r--sw/source/core/doc/docredln.cxx14
1 files changed, 14 insertions, 0 deletions
diff --git a/sw/source/core/doc/docredln.cxx b/sw/source/core/doc/docredln.cxx
index 7644a107200e..d02b1c3a7057 100644
--- a/sw/source/core/doc/docredln.cxx
+++ b/sw/source/core/doc/docredln.cxx
@@ -393,6 +393,20 @@ void SwRedlineTable::LOKRedlineNotification(RedlineNotification nType, SwRangeRe
aRedline.put("textRange", sRects.getStr());
lcl_LOKInvalidateStartEndFrames(aCursor);
+
+ // When this notify method is called text invalidation is not done yet
+ // Calling FillRects updates the text area so invalidation will not run on the correct rects
+ // So we need to do an own invalidation here. It invalidates text frames continging the redlining
+ SwDoc* pDoc = pRedline->GetDoc();
+ SwViewShell* pSh;
+ if( pDoc && !pDoc->IsInDtor() &&
+ nullptr != ( pSh = pDoc->getIDocumentLayoutAccess().GetCurrentViewShell()) )
+ {
+ for(SwNodeIndex nIdx = pStartPos->nNode; nIdx <= pEndPos->nNode; ++nIdx)
+ {
+ pSh->InvalidateWindows( nIdx.GetNode().GetContentNode()->FindLayoutRect() );
+ }
+ }
}
boost::property_tree::ptree aTree;