X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/1832043f93af07af3f4891d9a95c4d4e1f70eec5..5ac1d44aa499901b1a2e194292ba7a93112196ae:/src/common/toplvcmn.cpp diff --git a/src/common/toplvcmn.cpp b/src/common/toplvcmn.cpp index a6c9133dbd..60376d3ebc 100644 --- a/src/common/toplvcmn.cpp +++ b/src/common/toplvcmn.cpp @@ -55,6 +55,8 @@ wxTopLevelWindowBase::wxTopLevelWindowBase() { // Unlike windows, top level windows are created hidden by default. m_isShown = false; + m_winDefault = NULL; + m_winTmpDefault = NULL; } wxTopLevelWindowBase::~wxTopLevelWindowBase() @@ -393,3 +395,14 @@ void wxTopLevelWindowBase::RequestUserAttention(int WXUNUSED(flags)) // it's probably better than do nothing, isn't it? Raise(); } + +void wxTopLevelWindowBase::RemoveChild(wxWindowBase *child) +{ + if ( child == m_winDefault ) + m_winDefault = NULL; + + if ( child == m_winTmpDefault ) + m_winTmpDefault = NULL; + + wxWindow::RemoveChild(child); +}