glib-sharp0.0.0.0neutralGtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details.A list class used by Gtk is managed wrapper for the underlying C list
implementation used by Gtk+. Various functions on the Gtk+
API take lists or return lists in this form.
The list deals with objects, these are pointers into
unmanaged resources.
For example to create a list of widgets, you would use the
following sample:
GLib.List MakeList (Gtk.Widget a, Gtk.Widget b)
{
GLib.List l = new GLib.List ((IntPtr) 0, typeof (Gtk.Widget));
l.Append (a.Handle);
l.Append (b.Handle);
}
The argument to the
constructor, allows the list enumerator code to return
properly wrapped or demarshalled objects from the unmanaged
world into the managed world.
GLib.ListBaseSystem.IDisposableSystem.Collections.ICollectionSystem.Collections.IEnumerableGLib.IWrapperSystem.ICloneableConstructorConstructs a List
A handle to a .
A new insteace instance of List, wrapping the C list. objects are constructed by passing an unmanaged
reference to an existing , or they can use
"(IntPtr) 0" as an initial value.
Using this constructor will not track the type information
of the classes or structures kept in the list. If you
plan on tracking the type information, use the method.
ConstructorInternal constructor
A handle to a GLib.list
A new instance of List, wrapping the C list. objects are constructed by passing an unmanaged
reference to an existing , or they can use
"(IntPtr) 0" as an initial value.
Using this constructor will track the type information
of the classes or structures kept in the list. This
information is used by the List enumerator when returning
data.
MethodSystem.ObjectDuplicates the list, shallow copy.The duplicated list.Makes a new copy of the list. The individual elements on
- the list are not duplicated.