call Layout() from Show(TRUE) to ensure that all dialogs are correctly laid out initially

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@17522 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2002-10-13 22:37:51 +00:00
parent a46cc43fed
commit 800e14138e

View File

@@ -296,6 +296,14 @@ bool wxDialog::Show(bool show)
if ( show )
{
// dialogs don't get WM_SIZE message after creation unlike most (all?)
// other windows and so could start their life non laid out correctly
// if we didn't call Layout() from here
//
// NB: normally we should call it just the first time but doing it
// every time is simpler than keeping a flag
Layout();
// usually will result in TransferDataToWindow() being called
InitDialog();
}