Ensure that message boxes with only "OK" can be closed with Escape in wxMSW.
authorVadim Zeitlin <vadim@wxwidgets.org>
Tue, 26 Apr 2011 22:57:30 +0000 (22:57 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Tue, 26 Apr 2011 22:57:30 +0000 (22:57 +0000)
commit18c8dd2be24fb5dcdb2a23e27a98abd67a1e0bde
tree7cf08d0743e5afd5bb22b31e8ddae410b9ca9573
parent6aacfc7320dd6e5e145848b4f25630d675f8fb10
Ensure that message boxes with only "OK" can be closed with Escape in wxMSW.

The native task dialog doesn't allow using Escape (nor Alt-F4 but this is less
annoying) to close it unless it has a Cancel button, so by default the dialogs
with only "OK" couldn't be closed with Escape.

Work around this by creating a Cancel button with "OK" label instead. This is
not ideal but there doesn't seem to be any other way to make this work.

See #12501.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67620 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
src/msw/msgdlg.cpp