diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2021-01-08 17:37:20 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2021-01-08 20:52:17 +0100 |
commit | c33dd70aa7a6a5dc28b99f8af123548b02a77884 (patch) | |
tree | aa22b0b5eb0e1635d12842b1c473b7ae56d7a47d /sd | |
parent | 5c9ace48f05269c50d57642256153450335ace5f (diff) |
tdf#128353 sd slideshow: fix handling of animgifs on slower machines
Regression from commit 3e0092031b73bad107e3122d5d4be2f5bd487744
(tdf#112318 sd opengl: fix lack of initial animation, 2019-04-05), the
problem was that in case a timer adds itself to the end of the scheduler
queue during Scheduler::ProcessEventsToIdle(), then the idle trigger in
SlideshowImpl::updateSlideShow() will never finish.
The intention of invoking idles is to help vcl backends which do the
actual painting in an idle, so actually it's enough to only process
tasks which are already scheduled. That is enough for skia/gtk3/etc and
avoids the problem with the animgifs.
This is only a problem in debug builds or on slower machines: the
animgif from the bugdoc wants to play a frame every 40ms, so in case
processing the current tasks finishes faster than that, then the problem
was not visible.
Change-Id: I7487cb9a79e7e5acc0b816eb4744a04559ae26ce
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108986
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/slideshow/slideshowimpl.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx index 0aa637d0dc43..5b4574261934 100644 --- a/sd/source/ui/slideshow/slideshowimpl.cxx +++ b/sd/source/ui/slideshow/slideshowimpl.cxx @@ -1678,7 +1678,8 @@ void SlideshowImpl::updateSlideShow() if (::basegfx::fTools::equalZero(fUpdate)) { // Make sure idle tasks don't starve when we don't have to wait. - Scheduler::ProcessEventsToIdle(); + // Don't process any events generated after invoking the function. + Application::Reschedule(/*bHandleAllCurrentEvents=*/true); } else { |