Make "Close" button affirmative ID in standard dialog button sizer.

This allows to use the Escape key to close a dialog with the "Close" button
only.

Closes #16185.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_3_0_BRANCH@76421 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2014-04-28 11:28:29 +00:00
parent 2b147475fd
commit affd4b2c13

View File

@@ -376,6 +376,8 @@ wxStdDialogButtonSizer *wxDialogBase::CreateStdDialogButtonSizer( long flags )
SetAffirmativeId(wxID_OK);
else if (flags & wxYES)
SetAffirmativeId(wxID_YES);
else if (flags & wxCLOSE)
SetAffirmativeId(wxID_CLOSE);
sizer->Realize();