[Libreoffice-commits] core.git: Branch 'libreoffice-5-1' - avmedia/source
Caolán McNamara
caolanm at redhat.com
Wed Jun 8 13:55:23 UTC 2016
avmedia/source/framework/mediaplayer.cxx | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
New commits:
commit 14a0b4a0883eb960896bd213c41e28957f1cda3c
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Jun 7 14:28:15 2016 +0100
Resolves: tdf#100258 crash on disposing media player
SfxDockingWindow::dispose() will call SetFloatingMode false
its floating, which recreates the mpMediaWindow and so
the assert occurs about living children.
So toggle out of floating mode before deleting mpMediaWindow
to avoid that
(cherry picked from commit ec2425ad5fb39df5ad952b27d49e172fdd7ff00d)
(cherry picked from commit 53d6094bd1337580dcd1c449f2bb696f03afb621)
Change-Id: I0b1cae149261fa43611b9f9a39465ce718e33484
Reviewed-on: https://gerrit.libreoffice.org/26019
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
diff --git a/avmedia/source/framework/mediaplayer.cxx b/avmedia/source/framework/mediaplayer.cxx
index c39af42..93da8e2 100644
--- a/avmedia/source/framework/mediaplayer.cxx
+++ b/avmedia/source/framework/mediaplayer.cxx
@@ -79,13 +79,16 @@ MediaFloater::~MediaFloater()
void MediaFloater::dispose()
{
+ if (IsFloatingMode())
+ {
+ Show(false, ShowFlags::NoFocusChange);
+ SetFloatingMode(false);
+ }
delete mpMediaWindow;
mpMediaWindow = nullptr;
SfxDockingWindow::dispose();
}
-
-
void MediaFloater::Resize()
{
SfxDockingWindow::Resize();
@@ -94,8 +97,6 @@ void MediaFloater::Resize()
mpMediaWindow->setPosSize( Rectangle( Point(), GetOutputSizePixel() ) );
}
-
-
void MediaFloater::ToggleFloatingMode()
{
::avmedia::MediaItem aRestoreItem;
More information about the Libreoffice-commits
mailing list