summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@collabora.com>2015-06-12 17:22:41 +0100
committerMichael Meeks <michael.meeks@collabora.com>2015-06-15 17:27:36 +0100
commita0faaf32381d30ca9dd834511271b7f45299c74c (patch)
tree4e4e5922eb7f819a9735c5d2c3dc0d00db52b0b4
parent9ee1e267f8811285c5d526f9b698897b2043059c (diff)
tdf#92036 - work around writer spelling issue
Issue exposed by fix for tdf#91727. Change-Id: Ia1eafbd4db28bcfa6c90e0d58735e232c7449f83 Reviewed-on: https://gerrit.libreoffice.org/16252 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
-rw-r--r--vcl/source/app/idle.cxx17
1 files changed, 15 insertions, 2 deletions
diff --git a/vcl/source/app/idle.cxx b/vcl/source/app/idle.cxx
index 0dd8593bff84..901c44e74cab 100644
--- a/vcl/source/app/idle.cxx
+++ b/vcl/source/app/idle.cxx
@@ -57,9 +57,22 @@ bool Idle::ReadyForSchedule( bool bTimer )
return true; // !bTimer
}
-sal_uInt64 Idle::UpdateMinPeriod( sal_uInt64 /* nMinPeriod */, sal_uInt64 /* nTime */ )
+sal_uInt64 Idle::UpdateMinPeriod( sal_uInt64 nMinPeriod, sal_uInt64 /* nTime */ )
{
- return 1;
+ switch (mePriority) {
+ case SchedulerPriority::HIGHEST:
+ case SchedulerPriority::HIGH:
+ case SchedulerPriority::RESIZE:
+ case SchedulerPriority::REPAINT:
+ nMinPeriod = 1; // don't wait.
+ break;
+ default:
+ // FIXME: tdf#92036 workaround, I should be 1 too - wait 5ms
+ if (nMinPeriod > 5)
+ nMinPeriod = 5;
+ break;
+ }
+ return nMinPeriod;
}