Fix message boxes with wxYES_NO|wxCANCEL style in wxMSW
Windows CE code removal in 8282c1be0f
(see
https://github.com/wxWidgets/wxWidgets/pull/81) broke message boxes showing
"Yes", "No" and "Cancel" buttons at once, add accidentally removed code back.
Closes https://github.com/wxWidgets/wxWidgets/pull/139
This commit is contained in:
@@ -460,7 +460,10 @@ int wxMessageDialog::ShowMessageBox()
|
|||||||
const long wxStyle = GetMessageDialogStyle();
|
const long wxStyle = GetMessageDialogStyle();
|
||||||
if ( wxStyle & wxYES_NO )
|
if ( wxStyle & wxYES_NO )
|
||||||
{
|
{
|
||||||
msStyle = MB_YESNO;
|
if ( wxStyle & wxCANCEL )
|
||||||
|
msStyle = MB_YESNOCANCEL;
|
||||||
|
else
|
||||||
|
msStyle = MB_YESNO;
|
||||||
|
|
||||||
if ( wxStyle & wxNO_DEFAULT )
|
if ( wxStyle & wxNO_DEFAULT )
|
||||||
msStyle |= MB_DEFBUTTON2;
|
msStyle |= MB_DEFBUTTON2;
|
||||||
|
Reference in New Issue
Block a user