]> git.saurik.com Git - wxWidgets.git/commitdiff
ExpandAll and ExpandAllChildren are in wxTreeCtrlBase now.
authorRobin Dunn <robin@alldunn.com>
Mon, 3 Jul 2006 20:55:39 +0000 (20:55 +0000)
committerRobin Dunn <robin@alldunn.com>
Mon, 3 Jul 2006 20:55:39 +0000 (20:55 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39959 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/generic/treectlg.h
src/generic/treectlg.cpp

index e6df2ee56c0a73bba959d04316c257288e4a96f8..f72b8fc4656abb10f4e5191c281c1caba7881263 100644 (file)
@@ -180,8 +180,6 @@ public:
 
     wxTreeItemId GetNext(const wxTreeItemId& item) const;
 
-    void ExpandAll(const wxTreeItemId& item);
-
 #if WXWIN_COMPATIBILITY_2_6
     // use EditLabel() instead
     void Edit( const wxTreeItemId& item ) { EditLabel(item); }
index f968f6a9b80051263f4f34964b84b37e7599bd94..eaea98d3badbac9859ed6d47ed595cbaeb8ecf06 100644 (file)
@@ -1628,25 +1628,6 @@ void wxGenericTreeCtrl::Expand(const wxTreeItemId& itemId)
     ProcessEvent( event );
 }
 
-void wxGenericTreeCtrl::ExpandAll(const wxTreeItemId& item)
-{
-    if ( !HasFlag(wxTR_HIDE_ROOT) || item != GetRootItem())
-    {
-        Expand(item);
-        if ( !IsExpanded(item) )
-            return;
-    }
-
-    wxTreeItemIdValue cookie;
-    wxTreeItemId child = GetFirstChild(item, cookie);
-    while ( child.IsOk() )
-    {
-        ExpandAll(child);
-
-        child = GetNextChild(item, cookie);
-    }
-}
-
 void wxGenericTreeCtrl::Collapse(const wxTreeItemId& itemId)
 {
     wxCHECK_RET( !HasFlag(wxTR_HIDE_ROOT) || itemId != GetRootItem(),
@@ -2620,7 +2601,7 @@ void wxGenericTreeCtrl::OnChar( wxKeyEvent &event )
             if ( !IsExpanded(m_current) )
             {
                 // expand all
-                ExpandAll(m_current);
+                ExpandAllChildren(m_current);
                 break;
             }
             //else: fall through to Collapse() it