applied valid part of patch #940683: "wxMessageBox autocompletion"

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27503 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Dimitri Schoolwerth
2004-05-29 15:45:24 +00:00
parent 3f42061b05
commit 53a6ac21b8

View File

@@ -747,7 +747,14 @@ wxWindow* wxGenericFindWindowAtPoint(const wxPoint& pt)
int wxMessageBox(const wxString& message, const wxString& caption, long style,
wxWindow *parent, int WXUNUSED(x), int WXUNUSED(y) )
{
wxMessageDialog dialog(parent, message, caption, style);
long decorated_style = style;
if ( ( style & ( wxICON_EXCLAMATION | wxICON_HAND | wxICON_INFORMATION | wxICON_QUESTION ) ) == 0 )
{
decorated_style |= ( style & wxYES ) ? wxICON_QUESTION : wxICON_INFORMATION ;
}
wxMessageDialog dialog(parent, message, caption, decorated_style);
int ans = dialog.ShowModal();
switch ( ans )