]> git.saurik.com Git - wxWidgets.git/blob - include/wx/univ/toplevel.h
temporary stubs for fullscreen functions
[wxWidgets.git] / include / wx / univ / toplevel.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/toplevel.h
3 // Purpose: Top level window, abstraction of wxFrame and wxDialog
4 // Author: Vaclav Slavik
5 // Id: $Id$
6 // Copyright: (c) 2001 SciTech Software, Inc. (www.scitechsoft.com)
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
9
10
11 #ifndef __WX_UNIV_TOPLEVEL_H__
12 #define __WX_UNIV_TOPLEVEL_H__
13
14 #ifdef __GNUG__
15 #pragma interface "univtoplevel.h"
16 #endif
17
18 #include "wx/univ/inpcons.h"
19
20 // ----------------------------------------------------------------------------
21 // constants
22 // ----------------------------------------------------------------------------
23
24 // frame decorations type flags used in wxRenderer and wxColourScheme
25 enum
26 {
27 wxTOPLEVEL_BORDER = 0x00000001,
28 wxTOPLEVEL_MAXIMIZED = 0x00000002,
29 wxTOPLEVEL_TITLEBAR = 0x00000004,
30 wxTOPLEVEL_RESIZEABLE = 0x00000008,
31 wxTOPLEVEL_ICON = 0x00000010,
32 wxTOPLEVEL_CLOSE_BUTTON = 0x00000020,
33 wxTOPLEVEL_MAXIMIZE_BUTTON = 0x00000040,
34 wxTOPLEVEL_MINIMIZE_BUTTON = 0x00000080,
35 wxTOPLEVEL_RESTORE_BUTTON = 0x00000100,
36 wxTOPLEVEL_HELP_BUTTON = 0x00000200,
37 wxTOPLEVEL_ACTIVE = 0x00000400
38 };
39
40 //-----------------------------------------------------------------------------
41 // wxTopLevelWindow
42 //-----------------------------------------------------------------------------
43
44 class WXDLLEXPORT wxTopLevelWindow : public wxTopLevelWindowNative
45 {
46 public:
47 // construction
48 wxTopLevelWindow() { Init(); }
49 wxTopLevelWindow(wxWindow *parent,
50 wxWindowID id,
51 const wxString& title,
52 const wxPoint& pos = wxDefaultPosition,
53 const wxSize& size = wxDefaultSize,
54 long style = wxDEFAULT_FRAME_STYLE,
55 const wxString& name = wxFrameNameStr)
56 {
57 Init();
58
59 Create(parent, id, title, pos, size, style, name);
60 }
61
62 bool Create(wxWindow *parent,
63 wxWindowID id,
64 const wxString& title,
65 const wxPoint& pos = wxDefaultPosition,
66 const wxSize& size = wxDefaultSize,
67 long style = wxDEFAULT_FRAME_STYLE,
68 const wxString& name = wxFrameNameStr);
69
70 // implement base class pure virtuals
71 virtual bool ShowFullScreen(bool show, long style = wxFULLSCREEN_ALL);
72 virtual wxPoint GetClientAreaOrigin() const;
73 virtual void DoGetClientSize(int *width, int *height) const;
74 virtual void DoSetClientSize(int width, int height);
75 virtual void SetIcon(const wxIcon& icon);
76
77 // implementation from now on
78 // --------------------------
79
80 protected:
81 // common part of all ctors
82 void Init();
83
84 // return wxTOPLEVEL_xxx combination based on current state of the frame
85 long GetDecorationsStyle() const;
86
87 DECLARE_DYNAMIC_CLASS(wxTopLevelWindow)
88 DECLARE_EVENT_TABLE()
89 void OnNcPaint(wxPaintEvent& event);
90
91 // TRUE if wxTLW should render decorations (aka titlebar) itself
92 static int ms_drawDecorations;
93 // true for currently active frame
94 bool m_isActive:1;
95 // version of icon for titlebar (16x16)
96 wxIcon m_titlebarIcon;
97
98 };
99
100 #endif // __WX_UNIV_TOPLEVEL_H__