SetSize() fixes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@1786 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -78,7 +78,7 @@ public:
|
|||||||
wxMDIChildFrame *GetActiveChild() const ;
|
wxMDIChildFrame *GetActiveChild() const ;
|
||||||
|
|
||||||
// Get the client window
|
// Get the client window
|
||||||
inline wxMDIClientWindow *GetClientWindow() const { return m_clientWindow; };
|
wxMDIClientWindow *GetClientWindow() const { return m_clientWindow; };
|
||||||
|
|
||||||
// Create the client window class (don't Create the window,
|
// Create the client window class (don't Create the window,
|
||||||
// just return a new class)
|
// just return a new class)
|
||||||
|
@@ -44,17 +44,17 @@ IMPLEMENT_DYNAMIC_CLASS(wxMDIChildFrame, wxFrame)
|
|||||||
IMPLEMENT_DYNAMIC_CLASS(wxMDIClientWindow, wxNotebook)
|
IMPLEMENT_DYNAMIC_CLASS(wxMDIClientWindow, wxNotebook)
|
||||||
|
|
||||||
BEGIN_EVENT_TABLE(wxMDIParentFrame, wxFrame)
|
BEGIN_EVENT_TABLE(wxMDIParentFrame, wxFrame)
|
||||||
EVT_SIZE(wxMDIParentFrame::OnSize)
|
EVT_SIZE(wxMDIParentFrame::OnSize)
|
||||||
EVT_ACTIVATE(wxMDIParentFrame::OnActivate)
|
EVT_ACTIVATE(wxMDIParentFrame::OnActivate)
|
||||||
EVT_SYS_COLOUR_CHANGED(wxMDIParentFrame::OnSysColourChanged)
|
EVT_SYS_COLOUR_CHANGED(wxMDIParentFrame::OnSysColourChanged)
|
||||||
END_EVENT_TABLE()
|
END_EVENT_TABLE()
|
||||||
|
|
||||||
BEGIN_EVENT_TABLE(wxMDIClientWindow, wxNotebook)
|
BEGIN_EVENT_TABLE(wxMDIClientWindow, wxNotebook)
|
||||||
EVT_SCROLL(wxMDIClientWindow::OnScroll)
|
EVT_SCROLL(wxMDIClientWindow::OnScroll)
|
||||||
EVT_NOTEBOOK_PAGE_CHANGED(wxID_NOTEBOOK_CLIENT_AREA, wxMDIClientWindow::OnPageChanged)
|
EVT_NOTEBOOK_PAGE_CHANGED(wxID_NOTEBOOK_CLIENT_AREA, wxMDIClientWindow::OnPageChanged)
|
||||||
END_EVENT_TABLE()
|
END_EVENT_TABLE()
|
||||||
|
|
||||||
#endif
|
#endif // USE_SHARED_LIBRARY
|
||||||
|
|
||||||
// Parent frame
|
// Parent frame
|
||||||
|
|
||||||
@@ -131,6 +131,11 @@ void wxMDIParentFrame::OnSize(wxSizeEvent& event)
|
|||||||
GetClientWindow()->SetSize(x, y, width, height);
|
GetClientWindow()->SetSize(x, y, width, height);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void wxMDIParentFrame::GetClientSize(int *width, int *height) const
|
||||||
|
{
|
||||||
|
return wxWindow::GetClientSize(width. height);
|
||||||
|
}
|
||||||
|
|
||||||
void wxMDIParentFrame::OnActivate(wxActivateEvent& event)
|
void wxMDIParentFrame::OnActivate(wxActivateEvent& event)
|
||||||
{
|
{
|
||||||
// Do nothing
|
// Do nothing
|
||||||
@@ -231,6 +236,18 @@ bool wxMDIParentFrame::ProcessEvent(wxEvent& event)
|
|||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void wxMDIParentFrame::DoSetSize(int x, int y,
|
||||||
|
int width, int height,
|
||||||
|
int sizeFlags)
|
||||||
|
{
|
||||||
|
return wxWindow::DoSetSize(x, y, width, height, sizeFlags);
|
||||||
|
}
|
||||||
|
|
||||||
|
void wxMDIParentFrame::DoSetClientSize(int width, int height)
|
||||||
|
{
|
||||||
|
return wxWindow::DoSetClientSize(width, height);
|
||||||
|
}
|
||||||
|
|
||||||
// Responds to colour changes, and passes event on to children.
|
// Responds to colour changes, and passes event on to children.
|
||||||
void wxMDIParentFrame::OnSysColourChanged(wxSysColourChangedEvent& event)
|
void wxMDIParentFrame::OnSysColourChanged(wxSysColourChangedEvent& event)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user