[vlc-commits] qt: release order in DComp compositor
Pierre Lamot
git at videolan.org
Thu Oct 29 09:08:27 CET 2020
vlc | branch: master | Pierre Lamot <pierre at videolabs.io> | Thu Oct 22 10:37:24 2020 +0200| [061abdfd2d7cc60eb0e7c45c30e8f9e410d8099f] | committer: Pierre Lamot
qt: release order in DComp compositor
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=061abdfd2d7cc60eb0e7c45c30e8f9e410d8099f
---
modules/gui/qt/maininterface/compositor_dcomp.cpp | 2 +-
modules/gui/qt/maininterface/compositor_dcomp_uisurface.cpp | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/modules/gui/qt/maininterface/compositor_dcomp.cpp b/modules/gui/qt/maininterface/compositor_dcomp.cpp
index 361746027d..0738488dd3 100644
--- a/modules/gui/qt/maininterface/compositor_dcomp.cpp
+++ b/modules/gui/qt/maininterface/compositor_dcomp.cpp
@@ -271,7 +271,6 @@ void CompositorDirectComposition::destroyMainInterface()
m_uiVisual.Reset();
}
m_uiSurface.reset();
- m_ui.reset();
m_rootVisual.Reset();
m_dcompTarget.Reset();
m_qmlVideoSurfaceProvider.reset();
@@ -280,6 +279,7 @@ void CompositorDirectComposition::destroyMainInterface()
delete m_rootWindow;
m_rootWindow = nullptr;
}
+ m_ui.reset();
}
bool CompositorDirectComposition::setupVoutWindow(vout_window_t *p_wnd)
diff --git a/modules/gui/qt/maininterface/compositor_dcomp_uisurface.cpp b/modules/gui/qt/maininterface/compositor_dcomp_uisurface.cpp
index 74f90fbdff..25217019a0 100644
--- a/modules/gui/qt/maininterface/compositor_dcomp_uisurface.cpp
+++ b/modules/gui/qt/maininterface/compositor_dcomp_uisurface.cpp
@@ -232,6 +232,8 @@ bool CompositorDCompositionUISurface::init()
CompositorDCompositionUISurface::~CompositorDCompositionUISurface()
{
+ if (m_rootItem)
+ delete m_rootItem;
if (m_uiWindow)
delete m_uiWindow;
if (m_uiRenderControl)
@@ -240,8 +242,6 @@ CompositorDCompositionUISurface::~CompositorDCompositionUISurface()
delete m_uiOffscreenSurface;
if (m_context)
delete m_context;
- if (m_rootItem)
- delete m_rootItem;
if (m_qmlEngine)
delete m_qmlEngine;
releaseSharedTexture();
More information about the vlc-commits
mailing list