]> git.saurik.com Git - wxWidgets.git/blame - interface/wx/persist/toplevel.h
wxMessageBox off the main thread lost result code.
[wxWidgets.git] / interface / wx / persist / toplevel.h
CommitLineData
0fa541e8
VZ
1/////////////////////////////////////////////////////////////////////////////
2// Name: wx/persist/toplevel.h
3// Purpose: interface of wxPersistentTLW
4// Author: Vadim Zeitlin
0fa541e8 5// Copyright: (c) 2009 Vadim Zeitlin <vadim@wxwidgets.org>
526954c5 6// Licence: wxWindows licence
0fa541e8
VZ
7/////////////////////////////////////////////////////////////////////////////
8
9/**
10 Persistence adapter for wxTopLevelWindow.
11
12 This adapter saves and restores the geometry (i.e. position and size) and
13 the state (iconized, maximized or normal) of top level windows. It can be
14 used with both wxFrame and wxDialog.
15
16 Note that it does @em not save nor restore the window visibility.
17 */
18class wxPersistentTLW : public wxPersistentWindow<wxTopLevelWindow>
19{
20public:
21 /**
22 Constructor.
23
24 @param book
25 The associated window.
26 */
27 wxPersistentTLW(wxTopLevelWindow *book);
28
29 /**
30 Save the current window geometry.
31 */
32 virtual void Save() const;
33
34 /**
35 Restore the window geometry.
36 */
37 virtual bool Restore();
38};
39
40/// Overload allowing persistence adapter creation for wxTopLevelWindow-derived
41/// objects.
42wxPersistentObject *wxCreatePersistentObject(wxTopLevelWindow *book);