Fix for unsafe use of a global pointer for focus window: now checks at destruct
time to see if we should NULL the pointer. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@9349 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2334,6 +2334,9 @@ bool wxWindow::Create( wxWindow *parent, wxWindowID id,
|
||||
|
||||
wxWindow::~wxWindow()
|
||||
{
|
||||
if (g_focusWindow == this)
|
||||
g_focusWindow = NULL;
|
||||
|
||||
m_isBeingDeleted = TRUE;
|
||||
m_hasVMT = FALSE;
|
||||
|
||||
|
@@ -2334,6 +2334,9 @@ bool wxWindow::Create( wxWindow *parent, wxWindowID id,
|
||||
|
||||
wxWindow::~wxWindow()
|
||||
{
|
||||
if (g_focusWindow == this)
|
||||
g_focusWindow = NULL;
|
||||
|
||||
m_isBeingDeleted = TRUE;
|
||||
m_hasVMT = FALSE;
|
||||
|
||||
|
Reference in New Issue
Block a user