- DECLARE_CLASS(wxDocMDIChildFrame)
-
- public:
- wxDocMDIChildFrame(wxDocument *doc, wxView *view, wxMDIParentFrame *frame, wxWindowID id,
- const wxString& title, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize,
- long type = wxDEFAULT_FRAME_STYLE, const wxString& name = "frame");
- ~wxDocMDIChildFrame(void);
-
- // Extend event processing to search the view's event table
- virtual bool ProcessEvent(wxEvent& event);
-
- void OnActivate(wxActivateEvent& event);
- void OnCloseWindow(wxCloseEvent& event);
-
- inline wxDocument *GetDocument(void) const { return m_childDocument; }
- inline wxView *GetView(void) const { return m_childView; }
- inline void SetDocument(wxDocument *doc) { m_childDocument = doc; }
- inline void SetView(wxView *view) { m_childView = view; }
- bool Destroy() { m_childView = (wxView *)NULL; return wxMDIChildFrame::Destroy(); }
- protected:
- wxDocument* m_childDocument;
- wxView* m_childView;
-
-DECLARE_EVENT_TABLE()
-
+public:
+ wxDocMDIChildFrame();
+ wxDocMDIChildFrame(wxDocument *doc, wxView *view, wxMDIParentFrame *frame, wxWindowID id,
+ const wxString& title, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize,
+ long type = wxDEFAULT_FRAME_STYLE, const wxString& name = wxFrameNameStr);
+ virtual ~wxDocMDIChildFrame();
+
+ bool Create(wxDocument *doc,
+ wxView *view,
+ wxMDIParentFrame *frame,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos = wxDefaultPosition,
+ const wxSize& size = wxDefaultSize,
+ long type = wxDEFAULT_FRAME_STYLE,
+ const wxString& name = wxFrameNameStr);
+
+ void OnActivate(wxActivateEvent& event);
+ void OnCloseWindow(wxCloseEvent& event);
+
+ inline wxDocument *GetDocument() const { return m_childDocument; }
+ inline wxView *GetView(void) const { return m_childView; }
+ inline void SetDocument(wxDocument *doc) { m_childDocument = doc; }
+ inline void SetView(wxView *view) { m_childView = view; }
+ bool Destroy() { m_childView = NULL; return wxMDIChildFrame::Destroy(); }
+
+protected:
+ void Init();
+
+ virtual bool TryValidator(wxEvent& event);
+
+ wxDocument* m_childDocument;
+ wxView* m_childView;
+
+private:
+ DECLARE_EVENT_TABLE()
+ DECLARE_CLASS(wxDocMDIChildFrame)
+ DECLARE_NO_COPY_CLASS(wxDocMDIChildFrame)