Fix a memory leak in the breakpoint window.

Parent message alerts by the active window.  This way if another window is open it isn't pushed behind the main window.  We probably should parent the message alerts by the calling window instead, but this may be good enough.
Make sure there is only one instance of some modeless windows (Cheats Manager and Net Play).


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7257 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Glenn Rice
2011-02-27 02:27:43 +00:00
parent 449e79aea5
commit 217ee43063
12 changed files with 98 additions and 78 deletions

View File

@ -341,7 +341,7 @@ CFrame::CFrame(wxFrame* parent,
bool ShowLogWindow,
long style)
: CRenderFrame(parent, id, title, pos, size, style)
, g_pCodeWindow(NULL)
, g_pCodeWindow(NULL), g_NetPlaySetupDiag(NULL), g_CheatsWindow(NULL)
, bRenderToMain(false), bNoWiimoteMsg(false)
, m_ToolBar(NULL), m_ToolBarDebug(NULL), m_ToolBarAui(NULL)
, m_GameListCtrl(NULL), m_Panel(NULL)
@ -667,7 +667,7 @@ void CFrame::OnHostMessage(wxCommandEvent& event)
#ifdef __WXGTK__
case IDM_PANIC:
bPanicResult = (wxYES == wxMessageBox(event.GetString(),
_("Warning"), event.GetInt() ? wxYES_NO : wxOK, this));
_("Warning"), event.GetInt() ? wxYES_NO : wxOK, wxGetActiveWindow()));
panic_event.Set();
break;
case IDM_KEYSTATE: