X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ee5e8025711fb3938bc62ec23297713caf63551c..650368d057896c5bf6b1f2294766e92b7dbb7f20:/src/gtk/mdi.cpp diff --git a/src/gtk/mdi.cpp b/src/gtk/mdi.cpp index 4b3a894b75..3612109580 100644 --- a/src/gtk/mdi.cpp +++ b/src/gtk/mdi.cpp @@ -21,7 +21,7 @@ // constants //----------------------------------------------------------------------------- -const int wxMENU_HEIGHT = 30; +const int wxMENU_HEIGHT = 27; //----------------------------------------------------------------------------- // globals @@ -38,7 +38,8 @@ static void gtk_page_size_callback( GtkWidget *WXUNUSED(widget), GtkAllocation* if ((win->m_x == alloc->x) && (win->m_y == alloc->y) && (win->m_width == alloc->width) && - (win->m_height == alloc->height)) + (win->m_height == alloc->height) && + (win->m_sizeSet)) { return; } @@ -119,12 +120,12 @@ void wxMDIParentFrame::GtkOnSize( int x, int y, int width, int height ) if (m_mdiMenuBar) { - m_mdiMenuBar->m_x = 1; - m_mdiMenuBar->m_y = 1; - m_mdiMenuBar->m_width = m_width-2; - m_mdiMenuBar->m_height = wxMENU_HEIGHT-2; - gtk_myfixed_move( GTK_MYFIXED(m_wxwindow), m_mdiMenuBar->m_widget, 1, 1 ); - gtk_widget_set_usize( m_mdiMenuBar->m_widget, m_width-2, wxMENU_HEIGHT-2 ); + m_mdiMenuBar->m_x = 0; + m_mdiMenuBar->m_y = 0; + m_mdiMenuBar->m_width = m_width; + m_mdiMenuBar->m_height = wxMENU_HEIGHT; + gtk_myfixed_move( GTK_MYFIXED(m_wxwindow), m_mdiMenuBar->m_widget, 0, 0 ); + gtk_widget_set_usize( m_mdiMenuBar->m_widget, m_width, wxMENU_HEIGHT ); } } @@ -134,12 +135,12 @@ void wxMDIParentFrame::SetMDIMenuBar( wxMenuBar *menu_bar ) m_mdiMenuBar = menu_bar; if (m_mdiMenuBar) { - m_mdiMenuBar->m_x = 1; - m_mdiMenuBar->m_y = 1; - m_mdiMenuBar->m_width = m_width-2; - m_mdiMenuBar->m_height = wxMENU_HEIGHT-2; - gtk_myfixed_move( GTK_MYFIXED(m_wxwindow), m_mdiMenuBar->m_widget, 1, 1 ); - gtk_widget_set_usize( m_mdiMenuBar->m_widget, m_width-2, wxMENU_HEIGHT-2 ); + m_mdiMenuBar->m_x = 0; + m_mdiMenuBar->m_y = 0; + m_mdiMenuBar->m_width = m_width; + m_mdiMenuBar->m_height = wxMENU_HEIGHT; + gtk_myfixed_move( GTK_MYFIXED(m_wxwindow), m_mdiMenuBar->m_widget, 0, 0 ); + gtk_widget_set_usize( m_mdiMenuBar->m_widget, m_width, wxMENU_HEIGHT ); m_mdiMenuBar->Show( TRUE ); } }