]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/notebook/notebook.cpp
refresh the MDI frame window menu whenever a child frame is shown/hidden (and not...
[wxWidgets.git] / samples / notebook / notebook.cpp
index ca1adf709a63e3789f18fdef4d068f62659955b0..0931f0a56d15fa7ab35ded22d76c3e23459a3033 100644 (file)
@@ -765,8 +765,11 @@ void MyFrame::OnBookCtrl(wxBookCtrlBaseEvent& event)
         else if ( eventType == ei.typeChanging )
         {
             const int idx = event.GetOldSelection();
+
+            // NB: can't use wxStaticCast here as wxBookCtrlBase is not in
+            //     wxRTTI
             const wxBookCtrlBase * const
-                book = wxStaticCast(event.GetEventObject(), wxBookCtrlBase);
+                book = wx_static_cast(wxBookCtrlBase *, event.GetEventObject());
             if ( idx != wxNOT_FOUND &&
                     book && book->GetPageText(idx) == VETO_PAGE_NAME )
             {