summaryrefslogtreecommitdiff
path: root/slideshow/source/engine/slideshowimpl.cxx
diff options
context:
space:
mode:
authorArmin Le Grand <alg@apache.org>2013-07-09 09:29:13 +0000
committerCaolán McNamara <caolanm@redhat.com>2013-07-09 14:50:50 +0100
commitcc7a301dad831f8113cc3d737e2f4d23061a65ac (patch)
tree58e4a2d678a076cb440ab4644d19c6c8fd585efb /slideshow/source/engine/slideshowimpl.cxx
parentc7e7160fa7d2afe6db1c11e200949d83f7187c36 (diff)
Resolves: #i118671# take emergency exit when local slideshow...
is disposed from executing macros (cherry picked from commit 58eca806173ea9ede4efda89a96996d147227473) Change-Id: Ifd07faa0a4bb051dea7b57b775eaf8818a7ce6d3
Diffstat (limited to 'slideshow/source/engine/slideshowimpl.cxx')
-rw-r--r--slideshow/source/engine/slideshowimpl.cxx12
1 files changed, 12 insertions, 0 deletions
diff --git a/slideshow/source/engine/slideshowimpl.cxx b/slideshow/source/engine/slideshowimpl.cxx
index a37cdbc3f0fb..f9e8ed8b58e0 100644
--- a/slideshow/source/engine/slideshowimpl.cxx
+++ b/slideshow/source/engine/slideshowimpl.cxx
@@ -2010,6 +2010,18 @@ sal_Bool SlideShowImpl::update( double & nNextTimeout )
// process queues
maEventQueue.process();
+
+ // #i118671# the call above may execute a macro bound to an object. In
+ // that case this macro may have destroyed this local sliseshow so that it
+ // is disposed (see bugdoc at task). In that case, detect this and exit
+ // gently from this slideshow. Do not forget to disable the scoped
+ // call to mpPresTimer, this will be deleted if we are disposed.
+ if (isDisposed())
+ {
+ scopeGuard.dismiss();
+ return false;
+ }
+
maActivitiesQueue.process();
// commit frame to screen