File: TMainTree.h

package info (click to toggle)
gentle 1.9+cvs20100605+dfsg-2
  • links: PTS, VCS
  • area: contrib
  • in suites: squeeze
  • size: 12,264 kB
  • ctags: 5,235
  • sloc: cpp: 41,571; ansic: 3,978; sh: 1,420; makefile: 291
file content (52 lines) | stat: -rwxr-xr-x 1,313 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/** \file
	\brief Contains the TMainTree and TMainTreeItem classes
*/

#ifndef _TMAINTREE_H_
#define _TMAINTREE_H_

#include "main.h"

class MyFrame ;
class ChildBase ;

/** \class TMainTreeItem
	\brief Item in TMainTree
*/
class TMainTreeItem : public wxTreeItemData
    {
    public :
    TMainTreeItem () : wxTreeItemData() {} ; ///< \brief Blank constructor
    TMainTreeItem ( ChildBase *_c ) : wxTreeItemData() { c = _c ; } ; ///< \brief Constructor
    ChildBase *c ; ///< \brief Pointer to the associated child
    } ;

/** \class TMainTree
	\brief The main tree class
*/
class TMainTree : public wxTreeCtrl
    {
    public :
    TMainTree ( wxSashLayoutWindow *parent , int i ) ;

    void initme () ;
    void addChild ( ChildBase *c , int type = TYPE_VECTOR ) ;
    void removeChild ( ChildBase *c ) ;

    void OnEvent ( wxTreeEvent &event ) ;
    void OnRightClick ( wxTreeEvent &event ) ;
    
    void OnCloseChild ( wxCommandEvent &event ) ;

    // Variables
    wxTreeItemId treeroot , vectors , primers , fragments , sequences , 
                    alignments , amino_acids , misc ;
                    
    private :
    ChildBase *lastChild ; ///< \brief Pointer to the last selected child
    
    DECLARE_EVENT_TABLE()
    } ;

#endif