X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f6bcfd974ef26faf6f91a62cac09827e09463fd1..4e5a4c69c540b430fba8efe5dae1bc1ffd5caeca:/src/gtk/mdi.cpp diff --git a/src/gtk/mdi.cpp b/src/gtk/mdi.cpp index b87d71f753..fc8b911281 100644 --- a/src/gtk/mdi.cpp +++ b/src/gtk/mdi.cpp @@ -225,9 +225,9 @@ void wxMDIParentFrame::OnInternalIdle() } } -void wxMDIParentFrame::GetClientSize(int *width, int *height ) const +void wxMDIParentFrame::DoGetClientSize(int *width, int *height ) const { - wxFrame::GetClientSize( width, height ); + wxFrame::DoGetClientSize( width, height ); } wxMDIChildFrame *wxMDIParentFrame::GetActiveChild() const @@ -297,7 +297,7 @@ wxMDIChildFrame::wxMDIChildFrame() { m_menuBar = (wxMenuBar *) NULL; m_page = (GtkNotebookPage *) NULL; - m_isFrame = TRUE; + m_isFrame = FALSE; } wxMDIChildFrame::wxMDIChildFrame( wxMDIParentFrame *parent, @@ -307,7 +307,7 @@ wxMDIChildFrame::wxMDIChildFrame( wxMDIParentFrame *parent, { m_menuBar = (wxMenuBar *) NULL; m_page = (GtkNotebookPage *) NULL; - m_isFrame = TRUE; + m_isFrame = FALSE; Create( parent, id, title, wxDefaultPosition, size, style, name ); } @@ -327,9 +327,9 @@ bool wxMDIChildFrame::Create( wxMDIParentFrame *parent, return wxWindow::Create( parent->GetClientWindow(), id, wxDefaultPosition, size, style, name ); } -void wxMDIChildFrame::GetClientSize( int *width, int *height ) const +void wxMDIChildFrame::DoGetClientSize( int *width, int *height ) const { - wxWindow::GetClientSize( width, height ); + wxWindow::DoGetClientSize( width, height ); } void wxMDIChildFrame::AddChild( wxWindowBase *child ) @@ -363,12 +363,12 @@ wxMenuBar *wxMDIChildFrame::GetMenuBar() const void wxMDIChildFrame::Activate() { -#if (GTK_MINOR_VERSION > 0) +#if defined(__WXGTK20__) || (GTK_MINOR_VERSION > 0) wxMDIParentFrame* parent = (wxMDIParentFrame*) GetParent(); GtkNotebook* notebook = GTK_NOTEBOOK(parent->m_widget); - gint pageno = gtk_notebook_page_num( notebook, m_page->child ); + gint pageno = gtk_notebook_page_num( notebook, m_widget ); gtk_notebook_set_page( notebook, pageno ); -#else +#else // GTK+ 1.0 // the only way I can see to do this under gtk+ 1.0.X would // be to keep track of page numbers, start at first and // do "next" enough times to get to this page number - messy @@ -402,7 +402,7 @@ void wxMDIChildFrame::SetTitle( const wxString &title ) wxMDIParentFrame* parent = (wxMDIParentFrame*) GetParent(); GtkNotebook* notebook = GTK_NOTEBOOK(parent->m_widget); - gtk_notebook_set_tab_label_text(notebook, m_page->child, title.mbc_str()); + gtk_notebook_set_tab_label_text(notebook, m_widget, title.mbc_str()); } //-----------------------------------------------------------------------------