From e25f954b9600dcac0954d68d346c0d7879f6b97a Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Sun, 10 Mar 2002 09:25:35 +0000 Subject: [PATCH] Moved Nano-X specific code from univ to x11 git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14536 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/univ/dialog.cpp | 12 ------------ src/x11/toplevel.cpp | 11 +++++++++++ 2 files changed, 11 insertions(+), 12 deletions(-) diff --git a/src/univ/dialog.cpp b/src/univ/dialog.cpp index cf1d19793b..6b42e73d02 100644 --- a/src/univ/dialog.cpp +++ b/src/univ/dialog.cpp @@ -153,18 +153,6 @@ bool wxDialog::Show(bool show) EndModal(wxID_CANCEL); } - // Not sure how to put this in platform-specific - // code just yet. Nano-X has to force a size event, - // else there's no initial size. -#if wxUSE_NANOX - if (show) - { - wxSizeEvent event(GetSize(), GetId()); - event.SetEventObject(this); - GetEventHandler()->ProcessEvent(event); - } -#endif - bool ret = wxDialogBase::Show(show); if ( show ) diff --git a/src/x11/toplevel.cpp b/src/x11/toplevel.cpp index d191faf6f1..123f4f836d 100644 --- a/src/x11/toplevel.cpp +++ b/src/x11/toplevel.cpp @@ -231,6 +231,17 @@ wxTopLevelWindowX11::~wxTopLevelWindowX11() bool wxTopLevelWindowX11::Show(bool show) { + // Nano-X has to force a size event, + // else there's no initial size. +#if wxUSE_NANOX + if (show) + { + wxSizeEvent event(GetSize(), GetId()); + event.SetEventObject(this); + GetEventHandler()->ProcessEvent(event); + } +#endif + return wxWindowX11::Show(show); }