ALBA
|
#include <albaGUITree.h>
Classes | |
class | albaGUITreeTableElement |
Public Member Functions | |
albaGUITree (wxWindow *parent, wxWindowID id=-1, bool CloseButton=false, bool HideTitle=false) | |
virtual | ~albaGUITree () |
void | Reset () |
bool | AddNode (long long node_id, long long parent_id, wxString label, bool expanded, int icon=0) |
bool | DeleteNode (long long node_id) |
bool | SetNodeLabel (long long node_id, wxString label) |
wxString | GetNodeLabel (long long node_id) |
bool | NodeHasChildren (long long node_id) |
long long | GetNodeParent (long long node_id) |
bool | SetNodeParent (long long node_id, long long parent_id) |
bool | SetNodeIcon (long long node_id, int icon) |
int | GetNodeIcon (long long node_id) |
bool | SelectNode (long long node_id) |
void | SetImageList (wxImageList *img) |
void | SortChildren (long long node_id=0) |
void | SetAutoSort (bool enable) |
bool | GetAutoSort () |
void | CollapseNode (long long node_id) |
void | ExpandNode (long long node_id) |
bool | IsNodeExpanded (long long node_id) |
void | SetListener (albaObserver *listener) |
wxTreeItemId | ItemFromNode (long long node_id) |
long long | NodeFromItem (wxTreeItemId &item) |
void | SetTreeStyle (long style) |
long | GetTreeStyle () |
bool | NodeExist (long long node_id) |
![]() | |
albaGUINamedPanel (wxWindow *parent, wxWindowID id=-1, bool CloseButton=false, bool HideTitle=false) | |
virtual | ~albaGUINamedPanel () |
void | Add (wxWindow *window, int option=0, int flag=wxEXPAND, int border=0) |
void | Add (wxSizer *sizer, int option=0, int flag=wxEXPAND, int border=0) |
bool | Remove (wxWindow *window) |
bool | Remove (wxSizer *sizer) |
void | SetTitle (wxString label) |
void | SetTitleColor (wxColour *color=NULL) |
wxBoxSizer * | GetTopSizer () |
wxPanel * | GetTopPanel () |
![]() | |
albaGUIPanel (wxWindow *parent, wxWindowID id, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL, const wxString &name="panel") | |
Protected Member Functions | |
virtual void | OnSelectionChanged (wxTreeEvent &event) |
void | OnSize (wxSizeEvent &event) |
void | DeleteNode2 (long long node_id) |
void | SetNodeParent2 (long long node_id, long long parent_id) |
int | CheckIconId (int icon) |
bool | IsRootHidden () |
Protected Attributes | |
bool | m_PreventNotify |
bool | m_Autosort |
long long | m_NodeRoot |
albaTreeCtrl * | m_NodeTree |
wxImageList * | m_NodeImages |
wxHashTable * | m_NodeTable |
albaObserver * | m_Listener |
![]() | |
wxPanel * | m_Top |
albaGUILab * | m_Label |
wxBoxSizer * | m_Sizer |
wxBoxSizer * | m_TopSizer |
albaGUINamedPanel * | m_NextPanel |
wxColour | m_Color |
Additional Inherited Members | |
![]() | |
albaGUIPanel * | m_NextPanel |
Definition at line 145 of file albaGUITree.h.
albaGUITree::albaGUITree | ( | wxWindow * | parent, |
wxWindowID | id = -1 , |
||
bool | CloseButton = false , |
||
bool | HideTitle = false |
||
) |
|
virtual |
void albaGUITree::Reset | ( | ) |
Clears all items in the tree.
bool albaGUITree::AddNode | ( | long long | node_id, |
long long | parent_id, | ||
wxString | label, | ||
bool | expanded, | ||
int | icon = 0 |
||
) |
Create a new tree item with the specified parent,label and icon.
Set parent = 0 to create the root. 0 is not a valid node_id.
bool albaGUITree::DeleteNode | ( | long long | node_id | ) |
Delete the specified node, and its subtree.
bool albaGUITree::SetNodeLabel | ( | long long | node_id, |
wxString | label | ||
) |
Set the label for the node.
wxString albaGUITree::GetNodeLabel | ( | long long | node_id | ) |
Get the label for the node.
Add by Mucci 19/09/2007
bool albaGUITree::NodeHasChildren | ( | long long | node_id | ) |
Check if the node has children.
Add by Mucci 19/09/2007
long long albaGUITree::GetNodeParent | ( | long long | node_id | ) |
Return the parent id of the node.
Add by Mucci 19/09/2007
bool albaGUITree::SetNodeParent | ( | long long | node_id, |
long long | parent_id | ||
) |
Move a node, and its subtree.
bool albaGUITree::SetNodeIcon | ( | long long | node_id, |
int | icon | ||
) |
Set the icon for the node.
int albaGUITree::GetNodeIcon | ( | long long | node_id | ) |
Return the icon index for the node 'node_id'.
bool albaGUITree::SelectNode | ( | long long | node_id | ) |
Select the node.
void albaGUITree::SetImageList | ( | wxImageList * | img | ) |
Set the images to be used for the nodes.
Must be set before adding any node. The default ImageList provide 4 icons : -1 gray dot -2 red dot -3 blue dot -4 yellow dot
void albaGUITree::SortChildren | ( | long long | node_id = 0 | ) |
Sort the children of node_id.
(not the subtree) give node_id = 0 to specify the root.
|
inline |
if autosort is on - the tree is always kept sorted
Definition at line 201 of file albaGUITree.h.
|
inline |
Get the autosort flag.
Definition at line 204 of file albaGUITree.h.
void albaGUITree::CollapseNode | ( | long long | node_id | ) |
collapse the children of node_id
void albaGUITree::ExpandNode | ( | long long | node_id | ) |
expand the children of node_id
bool albaGUITree::IsNodeExpanded | ( | long long | node_id | ) |
|
inline |
Set the Listener that will receive event-notification, the Listener can be changed any time
Definition at line 215 of file albaGUITree.h.
wxTreeItemId albaGUITree::ItemFromNode | ( | long long | node_id | ) |
Return the node item from node id.
long long albaGUITree::NodeFromItem | ( | wxTreeItemId & | item | ) |
Return node id from node item.
|
inline |
Definition at line 223 of file albaGUITree.h.
|
inline |
Definition at line 224 of file albaGUITree.h.
bool albaGUITree::NodeExist | ( | long long | node_id | ) |
Return true if node exist.
|
protectedvirtual |
Private function that notify the Listener of node selection and deselection.
Reimplemented in albaGUIVMEChooserTree, and albaGUICheckTree.
|
protected |
When tree is used on a wxNotebook m_NodeTree must be called on Sizing .
|
protected |
Delete recursively a node and its subtree.
|
protected |
Move a node, and its subtree.
|
protected |
Check that id is a valid index in the imagelist - return the (eventually clamped) value.
|
inlineprotected |
Definition at line 245 of file albaGUITree.h.
|
protected |
Definition at line 247 of file albaGUITree.h.
|
protected |
Definition at line 248 of file albaGUITree.h.
|
protected |
Definition at line 249 of file albaGUITree.h.
|
protected |
Definition at line 250 of file albaGUITree.h.
Referenced by albaGUICheckTree::GetTree().
|
protected |
Definition at line 251 of file albaGUITree.h.
|
protected |
Definition at line 252 of file albaGUITree.h.
|
protected |
Definition at line 253 of file albaGUITree.h.