]> de.git.xonotic.org Git - xonotic/netradiant.git/blob - contrib/pk3man/tree.h
* added pk3man and fixed it to compile for latest radiant
[xonotic/netradiant.git] / contrib / pk3man / tree.h
1 // Tree.h: interface for the CTree class.
2 //
3 //////////////////////////////////////////////////////////////////////
4
5 #if !defined(AFX_TREE_H__C0DDC824_48DF_4A80_B393_83FF736FCB98__INCLUDED_)
6 #define AFX_TREE_H__C0DDC824_48DF_4A80_B393_83FF736FCB98__INCLUDED_
7
8 #if _MSC_VER > 1000
9 #pragma once
10 #endif // _MSC_VER > 1000
11
12 #include "stdafx.h"
13 #include <string>
14
15 void cb_select_child (GtkWidget *root_tree, GtkWidget *child, GtkWidget *subtree);
16
17 class CTree
18 {
19 public:
20         CTree();
21         virtual ~CTree();
22
23         GtkWidget *m_pMainWnd;
24         GtkWidget *m_Tree;
25         GtkWidget *m_Root;
26
27         void Init(GtkWidget *win);
28         void AddPath(const char *path);
29         void AddFile(const char *file,GtkWidget *node=NULL);
30         GtkWidget *AddFolder(const char *folder, GtkWidget *node=NULL);
31         void RemovePath(const char*path);
32
33         void SelectChild(GtkWidget *child);
34         std::string GetSelected();
35         std::string GetFullPath(GtkWidget *item);
36
37         void Clear();
38
39 };
40
41 #endif // !defined(AFX_TREE_H__C0DDC824_48DF_4A80_B393_83FF736FCB98__INCLUDED_)