]> git.saurik.com Git - wxWidgets.git/blob - include/wx/dialog.h
Added wxFIXED_SIZE.
[wxWidgets.git] / include / wx / dialog.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/dialog.h
3 // Purpose: wxDialogBase class
4 // Author: Vadim Zeitlin
5 // Modified by:
6 // Created: 29.06.99
7 // RCS-ID: $Id$
8 // Copyright: (c) Vadim Zeitlin
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_DIALOG_H_BASE_
13 #define _WX_DIALOG_H_BASE_
14
15 #if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
16 #pragma interface "dialogbase.h"
17 #endif
18
19 #include "wx/defs.h"
20 #include "wx/containr.h"
21 #include "wx/toplevel.h"
22
23 WXDLLEXPORT_DATA(extern const wxChar*) wxDialogNameStr;
24
25 class WXDLLEXPORT wxDialogBase : public wxTopLevelWindow
26 {
27 public:
28 wxDialogBase() { Init(); }
29 virtual ~wxDialogBase() { }
30
31 void Init();
32
33 // the modal dialogs have a return code - usually the id of the last
34 // pressed button
35 void SetReturnCode(int returnCode) { m_returnCode = returnCode; }
36 int GetReturnCode() const { return m_returnCode; }
37
38 #if wxUSE_STATTEXT // && wxUSE_TEXTCTRL
39 // splits text up at newlines and places the
40 // lines into a vertical wxBoxSizer
41 wxSizer *CreateTextSizer( const wxString &message );
42 #endif // wxUSE_STATTEXT // && wxUSE_TEXTCTRL
43
44 #if wxUSE_BUTTON
45 // places buttons into a horizontal wxBoxSizer
46 wxSizer *CreateButtonSizer( long flags );
47 #endif // wxUSE_BUTTON
48
49 protected:
50 // the return code from modal dialog
51 int m_returnCode;
52
53 DECLARE_NO_COPY_CLASS(wxDialogBase)
54 DECLARE_EVENT_TABLE()
55 WX_DECLARE_CONTROL_CONTAINER();
56 };
57
58
59 #if defined(__WXUNIVERSAL__) && !defined(__WXMICROWIN__)
60 #include "wx/univ/dialog.h"
61 #else
62 #if defined(__WXMSW__)
63 #include "wx/msw/dialog.h"
64 #elif defined(__WXMOTIF__)
65 #include "wx/motif/dialog.h"
66 #elif defined(__WXGTK__)
67 #include "wx/gtk/dialog.h"
68 #elif defined(__WXMAC__)
69 #include "wx/mac/dialog.h"
70 #elif defined(__WXCOCOA__)
71 #include "wx/cocoa/dialog.h"
72 #elif defined(__WXPM__)
73 #include "wx/os2/dialog.h"
74 #endif
75 #endif
76
77 #endif
78 // _WX_DIALOG_H_BASE_