diff options
author | Louai Al-Khanji <louai.al-khanji@digia.com> | 2014-10-02 09:19:12 +0300 |
---|---|---|
committer | Louai Al-Khanji <louai.al-khanji@digia.com> | 2014-10-03 07:44:39 +0200 |
commit | b1cbc1289ffd36c6ac30b049b8f5f8730ee4889d (patch) | |
tree | 8896d73bed7186bbf1bbfb5f376f9d0d2f8ab8dc /src/platformsupport/eglconvenience/qeglplatformintegration.cpp | |
parent | d5576b1cb8422e38716c99aab34622b5dc23437c (diff) |
EGLFS: Fix plugin destruction (again)
The previous patch was flawed since by the time the QEglPlatformIntegration
destructor was called the virtual function table did not point to the methods in
QEglFsPlatformIntegration any more.
Change-Id: I310e5e3e734a22b44645ba912b579f193bcfae86
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Diffstat (limited to 'src/platformsupport/eglconvenience/qeglplatformintegration.cpp')
-rw-r--r-- | src/platformsupport/eglconvenience/qeglplatformintegration.cpp | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/src/platformsupport/eglconvenience/qeglplatformintegration.cpp b/src/platformsupport/eglconvenience/qeglplatformintegration.cpp index a6207cf402..10913ef094 100644 --- a/src/platformsupport/eglconvenience/qeglplatformintegration.cpp +++ b/src/platformsupport/eglconvenience/qeglplatformintegration.cpp @@ -95,15 +95,7 @@ QEGLPlatformIntegration::QEGLPlatformIntegration() QEGLPlatformIntegration::~QEGLPlatformIntegration() { - foreach (QWindow *w, qGuiApp->topLevelWindows()) - w->destroy(); - - delete m_screen; - - if (m_display != EGL_NO_DISPLAY) - eglTerminate(m_display); - destroy(); } void QEGLPlatformIntegration::initialize() @@ -126,7 +118,13 @@ void QEGLPlatformIntegration::initialize() void QEGLPlatformIntegration::destroy() { + foreach (QWindow *w, qGuiApp->topLevelWindows()) + w->destroy(); + + delete m_screen; + if (m_display != EGL_NO_DISPLAY) + eglTerminate(m_display); } QAbstractEventDispatcher *QEGLPlatformIntegration::createEventDispatcher() const |