Kaydet (Commit) fb5b2c55 authored tarafından Caolán McNamara's avatar Caolán McNamara

afl-eventtesting: crash if you close shell behind running presentation

Change-Id: Ib8f02ddfe3b74e97145e22aa88e6f97d52c39f7a
üst f4294091
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include "app.hrc" #include "app.hrc"
#include "strings.hrc" #include "strings.hrc"
#include "glob.hrc" #include "glob.hrc"
#include "slideshow.hxx"
#include "unokywds.hxx" #include "unokywds.hxx"
#include <svx/svxids.hrc> #include <svx/svxids.hrc>
#include "DrawDocShell.hxx" #include "DrawDocShell.hxx"
...@@ -263,6 +264,11 @@ ViewShellBase::ViewShellBase ( ...@@ -263,6 +264,11 @@ ViewShellBase::ViewShellBase (
*/ */
ViewShellBase::~ViewShellBase() ViewShellBase::~ViewShellBase()
{ {
rtl::Reference<SlideShow> xSlideShow(SlideShow::GetSlideShow(*this));
if (xSlideShow.is() && xSlideShow->dependsOn(this))
SlideShow::Stop(*this);
xSlideShow.clear();
// Tell the controller that the ViewShellBase is not available anymore. // Tell the controller that the ViewShellBase is not available anymore.
if (mpImpl->mpController.get() != NULL) if (mpImpl->mpController.get() != NULL)
mpImpl->mpController->ReleaseViewShellBase(); mpImpl->mpController->ReleaseViewShellBase();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment