From: Vadim Zeitlin Date: Thu, 1 Apr 2004 13:08:24 +0000 (+0000) Subject: show window from PostCreation() (which is called for the derived classes as well... X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/a433fbd51de352a2a1e64c56f42c957c9af789c5 show window from PostCreation() (which is called for the derived classes as well) instead of Create() (which is not) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26545 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/gtk/window.cpp b/src/gtk/window.cpp index 525ef71e7e..6a39ba448d 100644 --- a/src/gtk/window.cpp +++ b/src/gtk/window.cpp @@ -2732,9 +2732,6 @@ bool wxWindowGTK::Create( wxWindow *parent, PostCreation(); - if ( IsShown() ) - gtk_widget_show( m_widget ); - return TRUE; } @@ -2919,6 +2916,11 @@ void wxWindowGTK::PostCreation() } m_hasVMT = TRUE; + + // unless the window was created initially hidden (i.e. Hide() had been + // called before Create()), we should show it at GTK+ level as well + if ( IsShown() ) + gtk_widget_show( m_widget ); } void wxWindowGTK::ConnectWidget( GtkWidget *widget ) diff --git a/src/gtk1/window.cpp b/src/gtk1/window.cpp index 525ef71e7e..6a39ba448d 100644 --- a/src/gtk1/window.cpp +++ b/src/gtk1/window.cpp @@ -2732,9 +2732,6 @@ bool wxWindowGTK::Create( wxWindow *parent, PostCreation(); - if ( IsShown() ) - gtk_widget_show( m_widget ); - return TRUE; } @@ -2919,6 +2916,11 @@ void wxWindowGTK::PostCreation() } m_hasVMT = TRUE; + + // unless the window was created initially hidden (i.e. Hide() had been + // called before Create()), we should show it at GTK+ level as well + if ( IsShown() ) + gtk_widget_show( m_widget ); } void wxWindowGTK::ConnectWidget( GtkWidget *widget )