1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/gtk/msgdlg.h
3 // Purpose: wxMessageDialog for GTK+2
4 // Author: Vaclav Slavik
7 // Copyright: (c) Vaclav Slavik, 2003
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
11 #ifndef _WX_GTK_MSGDLG_H_
12 #define _WX_GTK_MSGDLG_H_
14 class WXDLLIMPEXP_CORE wxMessageDialog
: public wxMessageDialogBase
17 wxMessageDialog(wxWindow
*parent
, const wxString
& message
,
18 const wxString
& caption
= wxMessageBoxCaptionStr
,
19 long style
= wxOK
|wxCENTRE
,
20 const wxPoint
& pos
= wxDefaultPosition
);
22 virtual int ShowModal();
23 virtual bool Show(bool WXUNUSED(show
) = true) { return false; }
26 // implement some base class methods to do nothing to avoid asserts and
27 // GTK warnings, since this is not a real wxDialog.
28 virtual void DoSetSize(int WXUNUSED(x
), int WXUNUSED(y
),
29 int WXUNUSED(width
), int WXUNUSED(height
),
30 int WXUNUSED(sizeFlags
) = wxSIZE_AUTO
) {}
31 virtual void DoMoveWindow(int WXUNUSED(x
), int WXUNUSED(y
),
32 int WXUNUSED(width
), int WXUNUSED(height
)) {}
33 // override to convert wx mnemonics to GTK+ ones and handle stock ids
34 virtual void DoSetCustomLabel(wxString
& var
, const ButtonLabel
& label
);
37 // override to use stock GTK+ defaults instead of just string ones
38 virtual wxString
GetDefaultYesLabel() const;
39 virtual wxString
GetDefaultNoLabel() const;
40 virtual wxString
GetDefaultOKLabel() const;
41 virtual wxString
GetDefaultCancelLabel() const;
42 virtual wxString
GetDefaultHelpLabel() const;
44 // create the real GTK+ dialog: this is done from ShowModal() to allow
45 // changing the message between constructing the dialog and showing it
46 void GTKCreateMsgDialog();
48 DECLARE_DYNAMIC_CLASS(wxMessageDialog
)
51 #endif // _WX_GTK_MSGDLG_H_