]> git.saurik.com Git - wxWidgets.git/blame - include/wx/motif/dialog.h
added wxAuiToolBar
[wxWidgets.git] / include / wx / motif / dialog.h
CommitLineData
9b6dbb09 1/////////////////////////////////////////////////////////////////////////////
1c067fe3 2// Name: wx/motif/dialog.h
9b6dbb09
JS
3// Purpose: wxDialog class
4// Author: Julian Smart
5// Modified by:
6// Created: 17/09/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
65571936 9// Licence: wxWindows licence
9b6dbb09
JS
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_DIALOG_H_
13#define _WX_DIALOG_H_
14
b5dbe15d 15class WXDLLIMPEXP_FWD_CORE wxEventLoop;
7e1bcfa8 16
9b6dbb09 17// Dialog boxes
53a2db12 18class WXDLLIMPEXP_CORE wxDialog : public wxDialogBase
9b6dbb09 19{
9b6dbb09 20public:
bfc6fde4 21 wxDialog();
798a4529 22
bfc6fde4 23 wxDialog(wxWindow *parent, wxWindowID id,
83df96d6
JS
24 const wxString& title,
25 const wxPoint& pos = wxDefaultPosition,
26 const wxSize& size = wxDefaultSize,
27 long style = wxDEFAULT_DIALOG_STYLE,
28 const wxString& name = wxDialogNameStr)
bfc6fde4
VZ
29 {
30 Create(parent, id, title, pos, size, style, name);
31 }
e30285ab 32
bfc6fde4 33 bool Create(wxWindow *parent, wxWindowID id,
96be256b 34 const wxString& title,
83df96d6
JS
35 const wxPoint& pos = wxDefaultPosition,
36 const wxSize& size = wxDefaultSize,
37 long style = wxDEFAULT_DIALOG_STYLE,
38 const wxString& name = wxDialogNameStr);
e30285ab 39
d3c7fc99 40 virtual ~wxDialog();
e30285ab 41
bfc6fde4 42 virtual bool Destroy();
798a4529 43
96be256b 44 virtual bool Show(bool show = true);
798a4529 45
bfc6fde4 46 void SetTitle(const wxString& title);
e30285ab 47
bfc6fde4 48 void SetModal(bool flag);
e30285ab 49
dfe1eee3 50 virtual bool IsModal() const
1c067fe3 51 { return m_modalShowing; }
e30285ab 52
bfc6fde4
VZ
53 virtual int ShowModal();
54 virtual void EndModal(int retCode);
e30285ab 55
dfe1eee3 56 // Implementation
96be256b 57 virtual void ChangeFont(bool keepOriginalSize = true);
dfe1eee3
VZ
58 virtual void ChangeBackgroundColour();
59 virtual void ChangeForegroundColour();
2158f4d7
VZ
60 WXWidget GetTopWidget() const { return m_mainWidget; }
61 WXWidget GetClientWidget() const { return m_mainWidget; }
e30285ab 62
798a4529 63private:
02bcd285 64 virtual bool XmDoCreateTLW(wxWindow* parent,
f58585c0
VZ
65 wxWindowID id,
66 const wxString& title,
67 const wxPoint& pos,
68 const wxSize& size,
69 long style,
70 const wxString& name);
71
798a4529 72
bfc6fde4
VZ
73 //// Motif-specific
74 bool m_modalShowing;
7e1bcfa8 75 wxEventLoop* m_eventLoop;
798a4529 76
bfc6fde4
VZ
77protected:
78 virtual void DoSetSize(int x, int y,
2158f4d7
VZ
79 int width, int height,
80 int sizeFlags = wxSIZE_AUTO);
e30285ab 81
bfc6fde4 82 virtual void DoSetClientSize(int width, int height);
e30285ab 83
219ee9ba 84
bfc6fde4 85private:
0be27418 86 DECLARE_DYNAMIC_CLASS(wxDialog)
9b6dbb09
JS
87};
88
0be27418 89#endif // _WX_DIALOG_H_