]> git.saurik.com Git - wxWidgets.git/blame - interface/wx/persist/treebook.h
Make storing non-trivial data in wxThreadSpecificInfo possible.
[wxWidgets.git] / interface / wx / persist / treebook.h
CommitLineData
0fa541e8
VZ
1/////////////////////////////////////////////////////////////////////////////
2// Name: wx/persist/treebook.h
3// Purpose: interface of wxPersistentTreeBook
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 wxTreebook.
11
12 This adapter saves and restores the expanded branches of the wxTreeCtrl
13 used by wxTreebook, in addition to saving and restoring the selection as
14 implemented by the base wxPersistentBookCtrl class.
15 */
ee094b63 16class wxPersistentTreeBookCtrl : public wxPersistentBookCtrl
0fa541e8
VZ
17{
18public:
19 /**
20 Constructor.
21
22 @param book
23 The associated tree book control.
24 */
ee094b63 25 wxPersistentTreeBookCtrl(wxTreebook *book);
0fa541e8
VZ
26
27 /**
28 Save the currently opened branches.
29 */
30 virtual void Save() const;
31
32 /**
33 Restore the opened branches.
34
35 The book control must be initialized before calling this function, i.e.
36 all of its pages should be already added to it.
37 */
38 virtual bool Restore();
39};
40
41/// Overload allowing persistence adapter creation for wxTreebook objects.
42wxPersistentObject *wxCreatePersistentObject(wxTreebook *book);