diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-05-07 11:49:46 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-05-07 11:49:46 +0200 |
commit | 93f5d5a9190e0e03bf4822663652a4b068c44f75 (patch) | |
tree | 9ac61601b056acad6a6c83d728c684661d3f3271 /sd/source/ui/slideshow | |
parent | c6fdd34c16f415629222348631141c3e13af6d4a (diff) |
The opaque PostUserEvent IDs are actually pointers
...so declare them as such. This avoids the recurring mistake of storing such
IDs as sal_uInt32, truncating in 64 bit environments, causing RemoveUserEvent to
potentially not remove the event, it thus firing "too late" and probably causing
a crash.
While at it, consolidate the trivially unnecessary overloads of both
Application::PostUserEvent and Window::PostUserEvent. And in each of them, it
looks like deleting the mpLink member was missing from the failure branch.
Change-Id: Iab13afbb06e12ac15dec6a6b5b85a7e402a3c654
Diffstat (limited to 'sd/source/ui/slideshow')
-rw-r--r-- | sd/source/ui/slideshow/SlideShowRestarter.hxx | 2 | ||||
-rw-r--r-- | sd/source/ui/slideshow/slideshowimpl.cxx | 9 | ||||
-rw-r--r-- | sd/source/ui/slideshow/slideshowimpl.hxx | 5 |
3 files changed, 3 insertions, 13 deletions
diff --git a/sd/source/ui/slideshow/SlideShowRestarter.hxx b/sd/source/ui/slideshow/SlideShowRestarter.hxx index da82e5196cf0..05d8fe69c468 100644 --- a/sd/source/ui/slideshow/SlideShowRestarter.hxx +++ b/sd/source/ui/slideshow/SlideShowRestarter.hxx @@ -59,7 +59,7 @@ public: void Restart (bool bForce); private: - sal_Int32 mnEventId; + ImplSVEvent * mnEventId; ::rtl::Reference<SlideShow> mpSlideShow; ViewShellBase* mpViewShellBase; ::boost::shared_ptr<SlideShowRestarter> mpSelf; diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx index de55c65aa061..3f816c027587 100644 --- a/sd/source/ui/slideshow/slideshowimpl.cxx +++ b/sd/source/ui/slideshow/slideshowimpl.cxx @@ -539,7 +539,6 @@ SlideshowImpl::SlideshowImpl( const Reference< XPresentation2 >& xPresentation, , msVerb( "Verb" ) , mnEndShowEvent(0) , mnContextMenuEvent(0) -, mnUpdateEvent(0) , mxPresentation( xPresentation ) { if( mpViewShell ) @@ -622,12 +621,6 @@ void SAL_CALL SlideshowImpl::disposing() maUpdateTimer.Stop(); - if( mnUpdateEvent ) - { - Application::RemoveUserEvent( mnUpdateEvent ); - mnUpdateEvent = 0; - } - removeShapeEvents(); if( mxListenerProxy.is() ) @@ -1843,8 +1836,6 @@ IMPL_LINK_NOARG(SlideshowImpl, ReadyForNextInputHdl) */ IMPL_LINK_NOARG(SlideshowImpl, updateHdl) { - mnUpdateEvent = 0; - return updateSlideShow(); } diff --git a/sd/source/ui/slideshow/slideshowimpl.hxx b/sd/source/ui/slideshow/slideshowimpl.hxx index 73a481e1d8ce..074b667235f7 100644 --- a/sd/source/ui/slideshow/slideshowimpl.hxx +++ b/sd/source/ui/slideshow/slideshowimpl.hxx @@ -400,9 +400,8 @@ private: ::std::auto_ptr<PaneHider> mpPaneHider; - sal_uLong mnEndShowEvent; - sal_uLong mnContextMenuEvent; - sal_Int32 mnUpdateEvent; + ImplSVEvent * mnEndShowEvent; + ImplSVEvent * mnContextMenuEvent; css::uno::Reference< css::presentation::XPresentation2 > mxPresentation; ::rtl::Reference< SlideShowListenerProxy > mxListenerProxy; |