+//-----------------------------------------------------------------------------
+// wxDirItemData
+//-----------------------------------------------------------------------------
+
+class WXDLLEXPORT wxDirItemData : public wxTreeItemData
+{
+public:
+ wxDirItemData(wxString& path, wxString& name);
+ ~wxDirItemData();
+ bool HasSubDirs();
+ void SetNewDirName( wxString path );
+ wxString m_path, m_name;
+ bool m_isHidden;
+ bool m_hasSubDirs;
+};
+
+//-----------------------------------------------------------------------------
+// wxDirCtrl
+//-----------------------------------------------------------------------------
+
+class WXDLLEXPORT wxDirCtrl: public wxTreeCtrl
+{
+public:
+ bool m_showHidden;
+ wxTreeItemId m_rootId;
+
+ wxDirCtrl();
+ wxDirCtrl(wxWindow *parent, const wxWindowID id = -1,
+ const wxString &dir = wxDirDialogDefaultFolderStr,
+ const wxPoint& pos = wxDefaultPosition,
+ const wxSize& size = wxDefaultSize,
+ const long style = wxTR_HAS_BUTTONS,
+ const wxString& name = wxTreeCtrlNameStr );
+ void ShowHidden( const bool yesno );
+ void OnExpandItem(wxTreeEvent &event );
+ void OnCollapseItem(wxTreeEvent &event );
+ void OnBeginEditItem(wxTreeEvent &event );
+ void OnEndEditItem(wxTreeEvent &event );
+
+protected:
+ void CreateItems(const wxTreeItemId &parent);
+ void SetupSections();
+ wxArrayString m_paths, m_names;
+
+private:
+ DECLARE_EVENT_TABLE()
+ DECLARE_DYNAMIC_CLASS(wxDirCtrl)
+};
+