X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9c9cff0b45fbe6f00930cb4bac0d66567dada53f..6244848856584171db8cd74a7ff227250e46cc54:/src/msw/dialog.cpp diff --git a/src/msw/dialog.cpp b/src/msw/dialog.cpp index bad108e769..44919fc74c 100644 --- a/src/msw/dialog.cpp +++ b/src/msw/dialog.cpp @@ -47,6 +47,7 @@ extern wxList wxPendingDelete; IMPLEMENT_DYNAMIC_CLASS(wxDialog, wxPanel) BEGIN_EVENT_TABLE(wxDialog, wxPanel) + EVT_SIZE(wxDialog::OnSize) EVT_BUTTON(wxID_OK, wxDialog::OnOK) EVT_BUTTON(wxID_APPLY, wxDialog::OnApply) EVT_BUTTON(wxID_CANCEL, wxDialog::OnCancel) @@ -237,11 +238,6 @@ bool wxDialog::IsIconized(void) const return FALSE; } -void wxDialog::SetSize(int x, int y, int width, int height, int WXUNUSED(sizeFlags)) -{ - wxWindow::SetSize(x, y, width, height); -} - void wxDialog::SetClientSize(int width, int height) { HWND hWnd = (HWND) GetHWND(); @@ -573,6 +569,16 @@ bool wxDialog::OnClose(void) return FALSE; } +void wxDialog::OnSize(wxSizeEvent& WXUNUSED(event)) +{ + // if we're using constraints - do use them + #if wxUSE_CONSTRAINTS + if ( GetAutoLayout() ) { + Layout(); + } + #endif +} + void wxDialog::OnCloseWindow(wxCloseEvent& event) { // Compatibility