On Wed, 2005-09-14 at 10:32 -0700, Eric Butler wrote:
> I'd like to check if a node in the NodeStore is expanded,
> TreeView.GetRowExpanded takes a TreePath, but it doesnt look like
> theres any way to get a TreeNode's path because there is no way to get
> it's top-level index (Nodes.IndexOf). NodeStore already has a GetPath
> method but its marked internal, can we change this to be public?

IMHO, the real solution is to offer a wrapper that takes a TreeNode. A
consumer of NodeStore should *never* have to see a path.

I filed one similar bug:

                view.RowExpanded += delegate (object o, RowExpandedArgs args) {
                        TreeNode n = (TreeNode) Store.GetNode (args.Path);
                        n.PopulateChildrenAsync ();
                };

Shows up in my msdn browser code. Really, the RowExpanded events should
have the TreeNode as an argument, rather than forcing some incantation
like this.

-- Ben

_______________________________________________
Gtk-sharp-list maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/gtk-sharp-list

Reply via email to