Debian Codegraph @

wxcrafter/src/wxcTreeView.h

raw
1 #ifndef __wxcTreeView__
2 #define __wxcTreeView__
3
4 #include "NewFormWizard.h"
5 #include "wxcrafter.h"
6
7 #include "wx/defs.h"
8 #ifdef __WINDOWS__ // __WINDOWS__ defined by wx/defs.h
9 #include "wx/msw/wrapwin.h" // includes windows.h
10
11 // macro and function name crash fix
12 #if defined(AddForm)
13 #undef AddForm
14 #endif
15 #endif
16
17 class EventsEditorPane;
18 extern const wxEventType wxEVT_SHOW_WXCRAFTER_DESIGNER;
19
20 class wxAuiToolBar;
21 class wxCrafterPlugin;
22
23 class wxcTreeView : public wxcTreeViewBaseClass
24 {
25 wxCrafterPlugin* m_plugin;
26 EventsEditorPane* m_eventsPane;
27 wxArrayString m_fileList;
28 bool m_loadingProject;
29
30 protected:
31 virtual void OnWxcpComboxTextEnter(wxCommandEvent& event);
32 virtual void OnItemLabelEditEnd(wxTreeEvent& event);
33 virtual void OnWorkspaceOpenUI(wxUpdateUIEvent& event);
34 virtual void OnSashPositionChanged(wxSplitterEvent& event);
35 virtual void OnChar(wxKeyEvent& event);
36 void DoRefreshFileList(bool reloadFileList = true);
37
38 public:
39 wxcTreeView(wxWindow* parent, wxCrafterPlugin* plugin);
40 virtual ~wxcTreeView();
41
42 clTreeCtrl* GetTree() { return m_treeControls; }
43 virtual void OnItemSelected(wxTreeEvent& event);
44 void LoadProject(const wxFileName& filname);
45 void SaveProject();
46 void CloseProject(bool saveBeforeClose);
47 void OnProjectClosed(wxCommandEvent& event);
48
49 void AddForm(const NewFormDetails& fd);
50 DECLARE_EVENT_TABLE()
51 void OnOpen(wxCommandEvent& e);
52 void OnProjectSaved(wxCommandEvent& e);
53 void OnOpenUI(wxUpdateUIEvent& e);
54 void OnWorkspaceLoaded(clWorkspaceEvent& e);
55 void OnWorkspaceClosed(clWorkspaceEvent& e);
56
57 protected:
58 virtual void OnRefreshWxcpFiles(wxCommandEvent& event);
59 virtual void OnWxcpFileSelected(wxCommandEvent& event);
60 };
61
62 #endif // __wxcTreeView__