2005-04-26 Mike Kestner <mkestner@novell.com>

* gtk/NodeStore.cs : implement IEnumerable.

svn path=/trunk/gtk-sharp/; revision=43594
This commit is contained in:
Mike Kestner 2005-04-26 13:45:27 +00:00
parent b4a4db44dd
commit bb023fe221
3 changed files with 24 additions and 2 deletions

View file

@ -1,3 +1,7 @@
2005-04-26 Mike Kestner <mkestner@novell.com>
* gtk/NodeStore.cs : implement IEnumerable.
2005-04-24 Dan Winship <danw@novell.com> 2005-04-24 Dan Winship <danw@novell.com>
* pango/Attribute.cs: Base class for Pango attributes, a la * pango/Attribute.cs: Base class for Pango attributes, a la

View file

@ -130,5 +130,18 @@
</remarks> </remarks>
</Docs> </Docs>
</Member> </Member>
<Member MemberName="GetEnumerator">
<MemberSignature Language="C#" Value="public virtual System.Collections.IEnumerator GetEnumerator ();" />
<MemberType>Method</MemberType>
<ReturnValue>
<ReturnType>System.Collections.IEnumerator</ReturnType>
</ReturnValue>
<Parameters />
<Docs>
<summary>Gets an enumerator for the root nodes.</summary>
<returns>a <see cref="T:System.Collections.IEnumerator" /></returns>
<remarks>Children of root nodes are not enumerated. You must traverse them independently.</remarks>
</Docs>
</Member>
</Members> </Members>
</Type> </Type>

View file

@ -26,7 +26,7 @@ namespace Gtk {
using System.Reflection; using System.Reflection;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
public class NodeStore : GLib.Object { public class NodeStore : GLib.Object, IEnumerable {
class IDHashtable : Hashtable { class IDHashtable : Hashtable {
class IDComparer : IComparer { class IDComparer : IComparer {
@ -472,5 +472,10 @@ namespace Gtk {
return new GLib.GType (gtksharp_node_store_get_type ()); return new GLib.GType (gtksharp_node_store_get_type ());
} }
} }
public IEnumerator GetEnumerator ()
{
return nodes.GetEnumerator ();
}
} }
} }