1 \section{\class{wxDocMDIParentFrame
}}\label{wxdocmdiparentframe
}
3 The wxDocMDIParentFrame class provides a default top-level frame for
4 applications using the
document/view framework. This class can only be used for MDI parent frames.
6 It cooperates with the
\helpref{wxView
}{wxview
},
\helpref{wxDocument
}{wxdocument
},
7 \rtfsp\helpref{wxDocManager
}{wxdocmanager
} and
\helpref{wxDocTemplates
}{wxdoctemplate
} classes.
9 See the example application in
{\tt samples/docview
}.
11 \wxheading{Derived from
}
13 \helpref{wxMDIParentFrame
}{wxmdiparentframe
}\\
14 \helpref{wxFrame
}{wxframe
}\\
15 \helpref{wxWindow
}{wxwindow
}\\
16 \helpref{wxEvtHandler
}{wxevthandler
}\\
17 \helpref{wxObject
}{wxobject
}
19 \wxheading{Include files
}
25 \helpref{Document/view overview
}{docviewoverview
},
\helpref{wxMDIParentFrame
}{wxmdiparentframe
}
27 \latexignore{\rtfignore{\wxheading{Members
}}}
29 \membersection{wxDocMDIParentFrame::wxDocMDIParentFrame
}\label{wxdocmdiparentframector
}
31 \func{}{wxDocMDIParentFrame
}{\void}
33 \func{}{wxDocMDIParentFrame
}{\param{wxDocManager*
}{ manager
},
\param{wxFrame *
}{parent
},
\param{wxWindowID
}{ id
},
34 \param{const wxString\&
}{title
},
\param{const wxPoint\&
}{ pos = wxDefaultPosition
},
35 \param{const wxSize\&
}{ size = wxDefaultSize
},
36 \param{long
}{ style = wxDEFAULT
\_FRAME\_STYLE},
\param{const wxString\&
}{name = "frame"
}}
40 \membersection{wxDocMDIParentFrame::
\destruct{wxDocMDIParentFrame
}}\label{wxdocmdiparentframedtor
}
42 \func{}{\destruct{wxDocMDIParentFrame
}}{\void}
46 \membersection{wxDocMDIParentFrame::Create
}\label{wxdocmdiparentframecreate
}
48 \func{bool
}{Create
}{\param{wxDocManager*
}{ manager
},
\param{wxFrame *
}{parent
},
\param{wxWindowID
}{ id
},
49 \param{const wxString\&
}{title
},
\param{const wxPoint\&
}{ pos = wxDefaultPosition
},
50 \param{const wxSize\&
}{ size = wxDefaultSize
},
51 \param{long
}{ style = wxDEFAULT
\_FRAME\_STYLE},
\param{const wxString\&
}{name = "frame"
}}
55 \membersection{wxDocMDIParentFrame::OnCloseWindow
}\label{wxdocmdiparentframeonclosewindow
}
57 \func{void
}{OnCloseWindow
}{\param{wxCloseEvent\&
}{ event
}}
59 Deletes all views and documents. If no user input cancelled the
60 operation, the frame will be destroyed and the application will exit.
62 Since understanding how
document/view clean-up takes place can be difficult,
63 the implementation of this function is shown below.
66 void wxDocParentFrame::OnCloseWindow(wxCloseEvent& event)
68 if (m_docManager->Clear(!event.CanVeto()))