diff options
author | Marco Cecchetti <marco.cecchetti@collabora.com> | 2017-05-11 13:08:02 +0200 |
---|---|---|
committer | Jan Holesovsky <kendy@collabora.com> | 2017-05-11 17:55:01 +0200 |
commit | b973b184a0870ad70e2db4e0e3842cf208b87abf (patch) | |
tree | c749c88646c1e397cde5357c676db643e9f76aa9 /libreofficekit | |
parent | 99c99e3c7546f98b3d21301e6160772ee9f47fc0 (diff) |
lok: sw: change tracking: deleted characters aren't deleted right away
Problem:
Start/open a document in CS Writer, and enable track changes.
- Type a few characters.
- Delete a couple of them with backspace or delete.
=> The deleted characters are still shown in the document (but not in
the tracking comment).
Findings:
In SwViewShell::ImplEndAction pRegion is 0, so no call to
SwRootFrame::Paint->vcl::Window::Invalidate occurs.
That is due to the fact that the call to SwLayAction::Action() does
not lead to populating *pRegion with rectangles
(SwViewShellImp::AddPaintRect).
In fact we stop at SwLayAction::TurboAction_ since pCnt->IsValid()
returns true and so SwLayAction::PaintContent() is never invoked.
SwFrame::IsValid() returns: mbValidPos && mbValidSize &&
mbValidPrtArea.
Here SwFrame::mbValidSize is the one that makes the difference: it is
true in Online and false in Desktop. (In our case the other 2 data
members are always true).
The reason is that the computation of the text range
(SwShellCursor::FillRects) in SwRedlineTable::LOKRedlineNotification,
which occurs just before collecting paint rectangles, leads to invoke
SwContentFrame::MakeAll which in turns set SwFrame::mbValidSize to
true.
Solution:
Call SwFrame::InvalidateSize() on any frame on which MakeAll is
invoked soon after we finish to compute the text range in
SwRedlineTable::LOKRedlineNotification.
Change-Id: Id5e29b06c044f14207722e67d6f5facbf786ffa6
Reviewed-on: https://gerrit.libreoffice.org/37508
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Diffstat (limited to 'libreofficekit')
0 files changed, 0 insertions, 0 deletions