X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/33d0b396b23cc198d6966d2ae4bd03762821e56c..cf5f9c9c3e06f4d1104fdeabc61c5e756a24c872:/src/gtk/window.cpp diff --git a/src/gtk/window.cpp b/src/gtk/window.cpp index 74ab35d9c7..daa0725468 100644 --- a/src/gtk/window.cpp +++ b/src/gtk/window.cpp @@ -1055,10 +1055,24 @@ void wxWindow::ImplementSetSize(void) void wxWindow::ImplementSetPosition(void) { + if (!m_parent) + { + if (IsKindOf(CLASSINFO(wxFrame)) || + IsKindOf(CLASSINFO(wxDialog))) + { + gtk_widget_set_uposition( m_widget, m_x, m_y ); + } + else + { + printf( "wxWindow::SetSize error.\n" ); + } + return; + } + if ((m_parent) && (m_parent->m_wxwindow)) gtk_myfixed_move( GTK_MYFIXED(m_parent->m_wxwindow), m_widget, m_x, m_y ); - else - gtk_widget_set_uposition( m_widget, m_x, m_y ); + + // Don't do anything for children of wxNotebook and wxMDIChildFrame }; void wxWindow::SetSize( int x, int y, int width, int height, int sizeFlags )