This is a big one, it is the representation of a class in a tree. It has to be somewhat tricky as this class can either be the root of the ClassTree, or it can be a member class.
void Attach( const wxTreeItemId& NodeId)
std::string GetStringRepresentation( )
ObjectPtr GetObject( )
void SetNodeText( const std::string& NewText)
bool AcceptDrop( TreeView* pDroppedView, const wxTreeItemId& ReferenceId)
void ShowContextMenu( const wxPoint& Position)
void HandleContextMenuEvent( wxTreeItemId SourceID, wxCommandEvent& Event)
- wxTreeItemId SourceID: the source of this event. Could be different from this view (if the user clicked on public for example)
bool CanContain( TreeView* pView) const
bool CanBeContainedByClass( ClassObjectPtr pClass) constFor this object it's a bit tricky. In general a class can be contained by a class. HOWEVER it's possible that a user is dragging this class inside itself. So this function has to make sure that doesn't return true.
void DeleteChild( TreeView* pChild)
ClassTreeView( ClassTree* pTree, ClassObjectPtr pClass)
ClassObject::AccessType GetAccessTypeForItem( const wxTreeItemId& Item) const
void ViewDocColours( bool Enable)Call this one to assign colours to thing in the tree based on how out of date they are with their docs.
void ColourCodeChildren( const wxTreeItemId& ParentID, bool Enabled)Helper function for OutdatedDocColoutCode
void BuildObjectList( const ObjectPtrList& Objects, const wxTreeItemId& ParentID)
std::string GetEditableLabel( )When the user clicks on the label they will be able to edit it directly. This gets the text that will show up in the edit box.
bool OnLabelChanged( const std::string& NewLabel)Called when the user is done entering text into the tree label. Children will need to parse this and set their data accordingly.
void ShowInfo( )
void OnCreateVariable( ClassObject::AccessType Access)
void OnCreateMethod( ClassObject::AccessType Access)
void OnCreateOther( ClassObject::AccessType Access)
void OnCreateClass( ClassObject::AccessType Access)
void OnDeleteClass( )
wxTreeItemId GetAccessNode( ClassObject::AccessType& Access)
wxTreeItemId m_PublicNodeParent node for public members
wxTreeItemId m_PrivateNodeParent node for private members
wxTreeItemId m_ProtectedNodeParent node for protected members