On Mon, 2005-04-25 at 23:22 -0700, Eric Butler wrote:

> I couldn't find any simple way to get a list of all the nodes in a
> NodeStore. This one line method does the trick... unless I totally
> overlooked something (which happens quite often) could it please be added?
> 
> This is extremely useful because I can do something like:
> 
> public void on_mnuConnectionsClearDisconnected_activate(object o,
> EventArgs e)
>         {
>                 foreach (ConnectionListItem node in
> connectionList.NodeStore.GetNodes()) {

I just committed a patch to trunk to make NodeStore implement
IEnumerable.  Now you can do:

foreach (ConnectionListItem node in connectionList.NodeStore) {}

Keep in mind, this only iterates the root nodes.

Thanks for the patch.
-- 
Mike Kestner <[EMAIL PROTECTED]>

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

Reply via email to