$szTitle = "wxdocmdiparentframe"; include "./_header.inc"; ?>
the wxdocmdiparentframe class provides a default top-level frame for applications using the document/view framework. this class can only be used for mdi parent frames.
it cooperates with the wxview, wxdocument, wxdocmanager and wxdoctemplates classes.
see the example application in samples/docview.
derived from
wxmdiparentframe
wxframe
wxwindow
wxevthandler
wxobject
include files
<wx/docmdi.h>
see also
document/view overview, wxmdiparentframe
members
wxdocmdiparentframe::wxdocmdiparentframe
wxdocmdiparentframe::~wxdocmdiparentframe
wxdocmdiparentframe::create
wxdocmdiparentframe::onclosewindow
wxdocmdiparentframe()
wxdocmdiparentframe(wxdocmanager* manager, wxframe *parent, wxwindowid id, const wxstring& title, const wxpoint& pos = wxdefaultposition, const wxsize& size = wxdefaultsize, long style = wxdefault_frame_style, const wxstring& name = "frame")
constructor.
~wxdocmdiparentframe()
destructor.
bool create(wxdocmanager* manager, wxframe *parent, wxwindowid id, const wxstring& title, const wxpoint& pos = wxdefaultposition, const wxsize& size = wxdefaultsize, long style = wxdefault_frame_style, const wxstring& name = "frame")
creates the window.
void onclosewindow(wxcloseevent& event)
deletes all views and documents. if no user input cancelled the operation, the frame will be destroyed and the application will exit.
since understanding how document/view clean-up takes place can be difficult, the implementation of this function is shown below.
void wxdocparentframe::onclosewindow(wxcloseevent& event) { if (m_docmanager->clear(!event.canveto())) { this->destroy(); } else event.veto(); }include "./_footer.inc"; ?>