- MyTreeCtrl(wxWindow *parent, const wxWindowID id, const wxPoint& pos,
- const wxSize& size, long style);
- ~MyTreeCtrl();
-
- void AddItemsRecursively(const wxTreeItemId& idParent,
- size_t numChildren,
- size_t depth);
- void AddTestItemsToTree(size_t numChildren,
- size_t depth);
-
-
- void OnBeginDrag(wxTreeEvent& event);
- void OnBeginRDrag(wxTreeEvent& event);
- void OnBeginLabelEdit(wxTreeEvent& event);
- void OnEndLabelEdit(wxTreeEvent& event);
- void OnDeleteItem(wxTreeEvent& event);
- void OnGetInfo(wxTreeEvent& event);
- void OnSetInfo(wxTreeEvent& event);
- void OnItemExpanded(wxTreeEvent& event);
- void OnItemExpanding(wxTreeEvent& event);
- void OnItemCollapsed(wxTreeEvent& event);
- void OnItemCollapsing(wxTreeEvent& event);
- void OnSelChanged(wxTreeEvent& event);
- void OnSelChanging(wxTreeEvent& event);
- void OnKeyDown(wxTreeEvent& event);
-
- DECLARE_EVENT_TABLE()
+ enum
+ {
+ TreeCtrlIcon_Folder,
+ TreeCtrlIcon_File
+ };
+
+ MyTreeCtrl(wxWindow *parent, const wxWindowID id,
+ const wxPoint& pos, const wxSize& size,
+ long style);
+ virtual ~MyTreeCtrl();
+
+ void OnBeginDrag(wxTreeEvent& event);
+ void OnBeginRDrag(wxTreeEvent& event);
+ void OnBeginLabelEdit(wxTreeEvent& event);
+ void OnEndLabelEdit(wxTreeEvent& event);
+ void OnDeleteItem(wxTreeEvent& event);
+ void OnGetInfo(wxTreeEvent& event);
+ void OnSetInfo(wxTreeEvent& event);
+ void OnItemExpanded(wxTreeEvent& event);
+ void OnItemExpanding(wxTreeEvent& event);
+ void OnItemCollapsed(wxTreeEvent& event);
+ void OnItemCollapsing(wxTreeEvent& event);
+ void OnSelChanged(wxTreeEvent& event);
+ void OnSelChanging(wxTreeEvent& event);
+ void OnKeyDown(wxTreeEvent& event);
+
+private:
+ void AddItemsRecursively(const wxTreeItemId& idParent,
+ size_t nChildren,
+ size_t depth);
+
+ void AddTestItemsToTree(size_t numChildren,
+ size_t depth);
+
+ wxImageList *m_imageListNormal;
+
+ DECLARE_EVENT_TABLE()