Commits

Anonymous committed 242e959

implemented close child frame functionality

  • Participants
  • Parent commits 0b30373

Comments (0)

Files changed (1)

 {
     wxWindow* top_win = GetTopWindow();
     if (top_win) {
-        top_win->Close();
+        wxMDIParentFrame * parent = static_cast<wxMDIParentFrame*> (top_win);
+        if (parent) {
+            wxMDIChildFrame * child = parent->GetActiveChild();
+            if (child) {
+                child->Close();
+            }
+        }
     }
 }