Set wxProgressDialog::m_parent too
This, in addition to the previous commit, allows Centre() to work correctly as it needs to retrieve the parent window rectangle. See #17768.
This commit is contained in:
@@ -124,8 +124,8 @@ protected:
|
|||||||
// the dialog was shown
|
// the dialog was shown
|
||||||
void ReenableOtherWindows();
|
void ReenableOtherWindows();
|
||||||
|
|
||||||
// Set the top level parent we store from the parent window provided when
|
// Store the parent window as wxWindow::m_parent and also set the top level
|
||||||
// creating the dialog.
|
// parent reference we store in this class itself.
|
||||||
void SetTopParent(wxWindow* parent);
|
void SetTopParent(wxWindow* parent);
|
||||||
|
|
||||||
// return the top level parent window of this dialog (may be NULL)
|
// return the top level parent window of this dialog (may be NULL)
|
||||||
|
@@ -133,6 +133,7 @@ wxGenericProgressDialog::wxGenericProgressDialog(const wxString& title,
|
|||||||
|
|
||||||
void wxGenericProgressDialog::SetTopParent(wxWindow* parent)
|
void wxGenericProgressDialog::SetTopParent(wxWindow* parent)
|
||||||
{
|
{
|
||||||
|
m_parent = parent;
|
||||||
m_parentTop = GetParentForModalDialog(parent, GetWindowStyle());
|
m_parentTop = GetParentForModalDialog(parent, GetWindowStyle());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user