]>
git.saurik.com Git - wxWidgets.git/blob - contrib/include/wx/fl/frmview.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxFrameView and wxFrameManager classes.
4 // Author: Aleksandras Gluchovas
8 // Copyright: (c) Aleksandras Gluchovas
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
16 #pragma interface "frmview.h"
19 #include "wx/module.h"
22 #include "wx/fl/objstore.h"
25 class wxObjectStorage
;
27 #include "wx/fl/controlbar.h"
32 It is not clear what this class does. It is not used elsewhere in FL.
35 class wxFrameView
: public wxEvtHandler
38 wxStringList mTopMenus
;
39 wxFrameLayout
* mpLayout
;
40 wxFrameManager
* mpFrameMgr
;
43 friend class wxFrameManager
;
44 friend class wxFrameViewSerializer
;
47 void OnIdle( wxIdleEvent
& event
);
53 virtual void Activate();
54 virtual void Deactivate();
56 wxFrame
* GetParentFrame();
57 wxWindow
* GetClientWindow();
59 wxFrameManager
& GetFrameManager();
61 void RegisterMenu( const wxString
& topMenuName
);
64 wxFrameLayout
* GetLayout();
65 void SetLayout( wxFrameLayout
* pLayout
);
66 void SetToolUpdates( bool doToolUpdates
= TRUE
);
69 // hooks for specific frame-views
71 virtual void OnInit() {}
73 virtual void OnSerialize( wxObjectStorage
& store
) {}
74 virtual void OnActiveate() {}
75 virtual void OnDeactivate() {}
78 virtual void OnRecreate() {}
79 virtual void OnInitMenus() {}
87 It is not clear what this class does. It is not used elsewhere in FL.
90 class wxFrameManager
: wxObject
96 wxWindow
* mpClientWnd
;
99 wxObjectStorage mStore
;
102 wxString mSettingsFile
;
105 void DoSerialize( wxObjectStorage
& store
);
107 int GetViewNo( wxFrameView
* pView
);
108 void EnableMenusForView( wxFrameView
* pView
, bool enable
);
115 // if file name is empty, views are are not saved/loaded
117 virtual void Init( wxWindow
* pMainFrame
, const wxString
& settingsFile
= "" );
120 wxFrame
* GetParentFrame();
121 wxWindow
* GetParentWindow();
123 int GetActiveViewNo();
124 wxFrameView
* GetActiveView();
125 wxNode
* GetActiveViewNode();
127 wxFrameView
* GetView( int viewNo
);
129 void SetClinetWindow( wxWindow
* pFrameClient
);
130 wxWindow
* GetClientWindow();
132 void AddView( wxFrameView
* pFrmView
);
133 void RemoveView( wxFrameView
* pFrmView
);
135 void ActivateView( int viewNo
);
136 void ActivateView( wxFrameView
* pFrmView
);
137 void DeactivateCurrentView();
139 wxObjectStorage
& GetObjectStore();
144 bool ViewsAreLoaded();
147 #endif /* __FRMVIEW_G__ */