summaryrefslogtreecommitdiffstats
path: root/sd
diff options
context:
space:
mode:
authorThorsten Behrens <tbehrens@suse.com>2011-11-16 12:37:04 +0100
committerThorsten Behrens <tbehrens@suse.com>2011-11-16 12:39:23 +0100
commit84da4113b4ec80cccd5916bf1289564837d6d5f9 (patch)
tree963eb2b6c4777976dcd21cc5d04fe17c9410d039 /sd
parentRelated: i#113308 null pointer check for the unit test (diff)
downloadcore-84da4113b4ec80cccd5916bf1289564837d6d5f9.tar.gz
core-84da4113b4ec80cccd5916bf1289564837d6d5f9.zip
Fix slideshow crasher
Recursive event loop killed SlideshowImpl object under my hands - make it stay until we pop out of callstack again.
Diffstat (limited to 'sd')
-rw-r--r--sd/source/ui/slideshow/slideshowimpl.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx
index 867e3bd270ca..7de8329fc0e7 100644
--- a/sd/source/ui/slideshow/slideshowimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowimpl.cxx
@@ -1873,6 +1873,9 @@ IMPL_LINK( SlideshowImpl, updateHdl, Timer*, EMPTYARG )
IMPL_LINK( SlideshowImpl, PostYieldListener, void*, EMPTYARG )
{
+ // prevent me from deletion when recursing (App::Reschedule does)
+ const rtl::Reference<SlideshowImpl> this_(this);
+
Application::EnableNoYieldMode(false);
Application::RemovePostYieldListener(LINK(this, SlideshowImpl, PostYieldListener));
Application::Reschedule(true); // fix for fdo#32861 - process
@@ -1888,7 +1891,7 @@ IMPL_LINK( SlideshowImpl, PostYieldListener, void*, EMPTYARG )
sal_Int32 SlideshowImpl::updateSlideShow (void)
{
- // doing some nMagic
+ // prevent me from deletion when recursing (App::EnableYieldMode does)
const rtl::Reference<SlideshowImpl> this_(this);
Reference< XSlideShow > xShow( mxShow );