]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk/dialog.h
1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
7 // Copyright: (c) 1998 Robert Roebling, Julian Smart and Markus Holzem
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
12 #ifndef __GTKDIALOGH__
13 #define __GTKDIALOGH__
20 #include "wx/object.h"
21 #include "wx/string.h"
23 #include "wx/window.h"
25 //-----------------------------------------------------------------------------
27 //-----------------------------------------------------------------------------
31 //-----------------------------------------------------------------------------
33 //-----------------------------------------------------------------------------
37 //-----------------------------------------------------------------------------
39 //-----------------------------------------------------------------------------
41 extern const char *wxDialogNameStr
;
43 //-----------------------------------------------------------------------------
45 //-----------------------------------------------------------------------------
47 class wxDialog
: public wxWindow
49 DECLARE_DYNAMIC_CLASS(wxDialog
)
54 wxDialog( wxWindow
*parent
, wxWindowID id
, const wxString
&title
,
55 const wxPoint
&pos
= wxDefaultPosition
, const wxSize
&size
= wxDefaultSize
,
56 long style
= wxDEFAULT_DIALOG_STYLE
, const wxString
&name
= wxDialogNameStr
);
57 bool Create( wxWindow
*parent
, wxWindowID id
, const wxString
&title
,
58 const wxPoint
&pos
= wxDefaultPosition
, const wxSize
&size
= wxDefaultSize
,
59 long style
= wxDEFAULT_DIALOG_STYLE
, const wxString
&name
= wxDialogNameStr
);
61 void SetTitle(const wxString
& title
);
62 wxString
GetTitle(void) const;
64 void OnApply( wxCommandEvent
&event
);
65 void OnCancel( wxCommandEvent
&event
);
66 void OnOk( wxCommandEvent
&event
);
67 void OnPaint(wxPaintEvent
& event
);
68 void OnCloseWindow(wxCloseEvent
& event
);
70 void OnCharHook(wxKeyEvent& event);
72 virtual bool Show( bool show
);
73 virtual int ShowModal(void);
74 virtual void EndModal(int retCode
);
75 virtual bool IsModal(void) const { return ((GetWindowStyleFlag() & wxDIALOG_MODAL
) == wxDIALOG_MODAL
); }
76 virtual void InitDialog(void);
78 void OnOK(wxCommandEvent& event);
79 void OnApply(wxCommandEvent& event);
80 void OnCancel(wxCommandEvent& event);
95 #endif // __GTKDIALOGH__