Silent audio mixing fix; Xlib Vulkan destruction order fix

This commit is contained in:
Jack Andersen
2018-05-28 09:28:36 -10:00
parent d5ec7bcc1e
commit 3028e34b51
6 changed files with 53 additions and 23 deletions

View File

@@ -1111,13 +1111,9 @@ public:
~WindowXlib()
{
XLockDisplay(m_xDisp);
m_gfxCtx->destroy();
XUnmapWindow(m_xDisp, m_windowId);
XDestroyWindow(m_xDisp, m_windowId);
XFreeColormap(m_xDisp, m_colormapId);
XUnlockDisplay(m_xDisp);
APP->_deletedWindow(this);
_cleanup();
if (APP)
APP->_deletedWindow(this);
}
void setCallback(IWindowCallback* cb)
@@ -2013,7 +2009,21 @@ public:
return false;
}
void _cleanup()
{
if (m_gfxCtx)
{
XLockDisplay(m_xDisp);
m_gfxCtx->destroy();
m_gfxCtx.reset();
XUnmapWindow(m_xDisp, m_windowId);
XDestroyWindow(m_xDisp, m_windowId);
XFreeColormap(m_xDisp, m_colormapId);
XUnlockDisplay(m_xDisp);
}
}
ETouchType getTouchType() const
{
return m_touchType;