]>
Commit | Line | Data |
---|---|---|
0fa541e8 VZ |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: wx/persist/treebook.h | |
3 | // Purpose: interface of wxPersistentTreeBook | |
4 | // Author: Vadim Zeitlin | |
5 | // RCS-ID: $Id$ | |
6 | // Copyright: (c) 2009 Vadim Zeitlin <vadim@wxwidgets.org> | |
526954c5 | 7 | // Licence: wxWindows licence |
0fa541e8 VZ |
8 | ///////////////////////////////////////////////////////////////////////////// |
9 | ||
10 | /** | |
11 | Persistence adapter for wxTreebook. | |
12 | ||
13 | This adapter saves and restores the expanded branches of the wxTreeCtrl | |
14 | used by wxTreebook, in addition to saving and restoring the selection as | |
15 | implemented by the base wxPersistentBookCtrl class. | |
16 | */ | |
ee094b63 | 17 | class wxPersistentTreeBookCtrl : public wxPersistentBookCtrl |
0fa541e8 VZ |
18 | { |
19 | public: | |
20 | /** | |
21 | Constructor. | |
22 | ||
23 | @param book | |
24 | The associated tree book control. | |
25 | */ | |
ee094b63 | 26 | wxPersistentTreeBookCtrl(wxTreebook *book); |
0fa541e8 VZ |
27 | |
28 | /** | |
29 | Save the currently opened branches. | |
30 | */ | |
31 | virtual void Save() const; | |
32 | ||
33 | /** | |
34 | Restore the opened branches. | |
35 | ||
36 | The book control must be initialized before calling this function, i.e. | |
37 | all of its pages should be already added to it. | |
38 | */ | |
39 | virtual bool Restore(); | |
40 | }; | |
41 | ||
42 | /// Overload allowing persistence adapter creation for wxTreebook objects. | |
43 | wxPersistentObject *wxCreatePersistentObject(wxTreebook *book); |