[PATCH] Bug 50386 - Page count field makes scrolling impossible

Muhammad Haggag mhaggag at gmail.com
Mon Jun 4 11:39:09 PDT 2012


Hello.

= Bugs =
https://bugs.freedesktop.org/show_bug.cgi?id=50386
https://bugs.freedesktop.org/show_bug.cgi?id=50540

= Patch =
https://bugs.freedesktop.org/attachment.cgi?id=62532

= Patch review =
https://bugs.freedesktop.org/page.cgi?id=splinter.html&bug=50386&attachment=62532

= Change =
This patch fixes a regression caused by my fix for fdo#34772 (adding
word count to the status bar). The code used to count words was
wrapped in StartAction/EndAction, which seem to be meant for input
actions based on keyboard/mouse. EndAction calls UpdateCrsr with the
SwCrsrShell::SCROLLWIN flag, resulting in the behavior described in
fdo#50386 and fdo#50540.

We were calling it directly (Start/EndAction) and indirectly (through
SwWrtShell::GetUpdatedDocStat). I removed the
direct calls and replaced the SwWrtShell call with
SwDoc::GetUpdatedDocStat, which doesn't call Start/EndAction.

Can someone advise on whether we need the SwWait? It's there because I
initially copied the code from wordcountdialog.cxx, but I'm not sure
whether we actually need it (or need it to lock the dispatcher
either).

Regards,
--Muhammad


More information about the LibreOffice mailing list