#define wxDIALOG_DEFAULT_X 300
#define wxDIALOG_DEFAULT_Y 300
-#if !USE_SHARED_LIBRARY
IMPLEMENT_CLASS(wxMessageDialog, wxDialog)
-#endif
wxMessageDialog::wxMessageDialog(wxWindow *parent, const wxString& message, const wxString& caption,
long style, const wxPoint& pos)
msStyle = MB_YESNOCANCEL;
else
msStyle = MB_YESNO;
+
+ if (m_dialogStyle & wxNO_DEFAULT)
+ msStyle |= MB_DEFBUTTON2;
}
+
if (m_dialogStyle & wxOK)
{
if (m_dialogStyle & wxCANCEL)
msStyle |= MB_APPLMODAL;
else
msStyle |= MB_TASKMODAL;
-
- int msAns = MessageBox(hWnd, (LPCSTR)(const char *)m_message, (LPCSTR)(const char *)m_caption, msStyle);
+
+ int msAns = MessageBox(hWnd, (LPCTSTR)(const wxChar *)m_message, (LPCTSTR)(const wxChar *)m_caption, msStyle);
int ans = wxOK;
switch (msAns)
{