From: Vadim Zeitlin Date: Sun, 23 Sep 2012 22:49:01 +0000 (+0000) Subject: No changes, just reuse a bit of code in wxMSW wxMDIParentFrame. X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/0079c032f5cbbe649cef1c3577e5f78a6138d7b2 No changes, just reuse a bit of code in wxMSW wxMDIParentFrame. Call wxMDIChildFrame::Activate() instead of redoing the same thing. This also ensures that iconized MDI children are restored before being activated (see previous commit). See #13946. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72541 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/msw/mdi.cpp b/src/msw/mdi.cpp index 68faa155db..46e0166c80 100644 --- a/src/msw/mdi.cpp +++ b/src/msw/mdi.cpp @@ -628,9 +628,7 @@ void wxMDIParentFrame::OnMDIChild(wxCommandEvent& event) int childId = wxGetWindowId(child->GetHWND()); if ( childId == event.GetId() ) { - ::SendMessage( GetWinHwnd(GetClientWindow()), - WM_MDIACTIVATE, - (WPARAM)child->GetHWND(), 0); + wxStaticCast(child, wxMDIChildFrame)->Activate(); return; } }