X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/655719367ac5e131d9642e5783f3ecf64d1a3385..ebe47451544561fbe6e57808d604641d24109359:/src/generic/progdlgg.cpp diff --git a/src/generic/progdlgg.cpp b/src/generic/progdlgg.cpp index a812cb4736..95e23580b6 100644 --- a/src/generic/progdlgg.cpp +++ b/src/generic/progdlgg.cpp @@ -115,11 +115,7 @@ wxProgressDialog::wxProgressDialog(wxString const &title, m_maximum /= m_factor; #endif // __WXMSW__ - m_parentTop = parent; - while ( m_parentTop && m_parentTop->GetParent() ) - { - m_parentTop = m_parentTop->GetParent(); - } + m_parentTop = wxGetTopLevelParent(parent); wxLayoutConstraints *c; @@ -144,8 +140,8 @@ wxProgressDialog::wxProgressDialog(wxString const &title, if ( maximum > 0 ) { - // note that we can't use wxGA_SMOOTH because it happens to also mean - // wxDIALOG_MODAL and will cause the dialog to be modal. Have an extra + // note that we can't use wxGA_SMOOTH because it happens to + // cause the dialog to be modal. Have an extra // style argument to wxProgressDialog, perhaps. m_gauge = new wxGauge(this, -1, m_maximum, wxDefaultPosition, wxDefaultSize,