From 70f3fad6095afa8cfc1eed7a89f884a963250346 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Wed, 4 Jul 2001 16:45:14 +0000 Subject: [PATCH] corrected progress dialog appearance git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10822 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/generic/progdlgg.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/generic/progdlgg.cpp b/src/generic/progdlgg.cpp index da963d14fd..4fc3c97542 100644 --- a/src/generic/progdlgg.cpp +++ b/src/generic/progdlgg.cpp @@ -166,7 +166,6 @@ wxProgressDialog::wxProgressDialog(wxString const &title, nTimeLabels++; m_elapsed = CreateLabel(_("Elapsed time : "), &lastWindow); - SetTimeLabel(0, m_elapsed); } if ( style & wxPD_ESTIMATED_TIME ) @@ -241,6 +240,14 @@ wxProgressDialog::wxProgressDialog(wxString const &title, Show(TRUE); Enable(TRUE); // enable this window + // this one can be initialized even if the others are unknown for now + // + // NB: do it after calling Layout() to keep the labels correctly aligned + if ( m_elapsed ) + { + SetTimeLabel(0, m_elapsed); + } + // Update the display (especially on X, GTK) wxYield(); -- 2.45.2