2004-02-12 Mike Kestner <mkestner@ximian.com>
* gdk/Gdk.metadata : hide the GSList API * gdk/*.custom : manually wrap GSList api using typed arrays * gdk/gdk-api.xml : regen. svn path=/trunk/gtk-sharp/; revision=23031
This commit is contained in:
parent
6ea443884a
commit
766b004949
5 changed files with 50 additions and 2 deletions
|
@ -1,3 +1,9 @@
|
|||
2004-02-12 Mike Kestner <mkestner@ximian.com>
|
||||
|
||||
* gdk/Gdk.metadata : hide the GSList API
|
||||
* gdk/*.custom : manually wrap GSList api using typed arrays
|
||||
* gdk/gdk-api.xml : regen.
|
||||
|
||||
2004-02-12 Mike Kestner <mkestner@ximian.com>
|
||||
|
||||
* gtk/Accel.custom : s/List/SList
|
||||
|
|
21
gdk/DisplayManager.custom
Normal file
21
gdk/DisplayManager.custom
Normal file
|
@ -0,0 +1,21 @@
|
|||
// DisplayManager.custom - customizations to Gdk.DisplayManager
|
||||
//
|
||||
// Authors: Mike Kestner <mkestner@ximian.com>
|
||||
//
|
||||
// Copyright (c) 2004 Novell, Inc.
|
||||
|
||||
[DllImport("libgdk-win32-2.0-0.dll")]
|
||||
static extern IntPtr gdk_display_manager_list_displays (IntPtr raw);
|
||||
|
||||
public Display[] ListDisplays ()
|
||||
{
|
||||
IntPtr raw_ret = gdk_display_manager_list_displays (Handle);
|
||||
if (raw_ret == IntPtr.Zero)
|
||||
return new Display [0];
|
||||
GLib.SList list = new GLib.SList(raw_ret);
|
||||
Display[] result = new Display [list.Count];
|
||||
for (int i = 0; i < list.Count; i++)
|
||||
result [i] = list [i] as Display;
|
||||
return result;
|
||||
}
|
||||
|
|
@ -18,6 +18,7 @@
|
|||
<attr path="//object[@cname='GdkColormap']/method[@name='AllocColors']/*/*[@name='success']" name="array">1</attr>
|
||||
<attr path="//object[@cname='GdkColormap']/method[@name='QueryColor']/*/*[@type='GdkColor*']" name="pass_as">ref</attr>
|
||||
<attr path="//object[@cname='GdkColormap']/method[@name='FreeColors']/*/*[@type='GdkColor*']" name="array">1</attr>
|
||||
<attr path="//object[@cname='GdkDisplayManager']/method[@name='ListDisplays']" name="hidden">1</attr>
|
||||
<attr path="//object[@cname='GdkDrawable']/method[@name='DrawLines']" name="hidden">1</attr>
|
||||
<attr path="//object[@cname='GdkDrawable']/method[@name='DrawPolygon']" name="hidden">1</attr>
|
||||
<attr path="//object[@cname='GdkDrawable']/method[@name='GetSize']/*/*[@type='gint*']" name="pass_as">out</attr>
|
||||
|
@ -28,6 +29,7 @@
|
|||
<attr path="//object[@cname='GdkPixbuf']/method[@name='AddAlpha']" name="hidden">1</attr>
|
||||
<attr path="//object[@cname='GdkPixbuf']/method[@name='CompositeColorSimple']" name="hidden">1</attr>
|
||||
<attr path="//object[@cname='GdkPixbuf']/method[@name='GetFromDrawable']" name="library">libgdk-win32-2.0-0.dll</attr>
|
||||
<attr path="//object[@cname='GdkPixbuf']/method[@name='GetFormats']" name="hidden">1</attr>
|
||||
<attr path="//object[@cname='GdkPixbuf']/method[@name='GetFromImage']" name="library">libgdk-win32-2.0-0.dll</attr>
|
||||
<attr path="//object[@cname='GdkPixbuf']/method[@name='GetPixels']" name="hidden">1</attr>
|
||||
<attr path="//object[@cname='GdkPixbuf']/method[@name='RenderThresholdAlpha']" name="library">libgdk-win32-2.0-0.dll</attr>
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
// Authors:
|
||||
// Vladimir Vukicevic <vladimir@pobox.com>
|
||||
// Miguel de Icaza <miguel@ximian.com>
|
||||
// Mike Kestner <mkestner@ximian.com>
|
||||
// Duncan Mak <duncan@ximian.com>
|
||||
// Gonzalo Paniagua Javier <gonzalo@ximian.com>
|
||||
// Martin Willemoes Hansen <mwh@sysrq.dk>
|
||||
|
@ -12,6 +13,7 @@
|
|||
// (C) 2003 Ximian, Inc. (Duncan Mak)
|
||||
// (C) 2003 Ximian, Inc. (Gonzalo Paniagua Javier)
|
||||
// (C) 2003 Martin Willemoes Hansen
|
||||
// (C) 2004 Novell, Inc.
|
||||
//
|
||||
// This code is inserted after the automatically generated code.
|
||||
|
||||
|
@ -165,3 +167,20 @@
|
|||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("libgdk_pixbuf-2.0-0.dll")]
|
||||
static extern IntPtr gdk_pixbuf_get_formats();
|
||||
|
||||
public static PixbufFormat[] Formats {
|
||||
get {
|
||||
IntPtr list_ptr = gdk_pixbuf_get_formats ();
|
||||
if (list_ptr == IntPtr.Zero)
|
||||
return new PixbufFormat [0];
|
||||
GLib.SList list = new GLib.SList (list_ptr, typeof (PixbufFormat));
|
||||
PixbufFormat[] result = new PixbufFormat [list.Count];
|
||||
for (int i = 0; i < list.Count; i++)
|
||||
result [i] = (PixbufFormat) list [i];
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -766,7 +766,7 @@
|
|||
<method name="GetType" cname="gdk_display_manager_get_type" shared="true">
|
||||
<return-type type="GType" />
|
||||
</method>
|
||||
<method name="ListDisplays" cname="gdk_display_manager_list_displays">
|
||||
<method name="ListDisplays" cname="gdk_display_manager_list_displays" hidden="1">
|
||||
<return-type type="GSList*" />
|
||||
</method>
|
||||
<method name="SetDefaultDisplay" cname="gdk_display_manager_set_default_display">
|
||||
|
@ -3714,7 +3714,7 @@
|
|||
<method name="GetColorspace" cname="gdk_pixbuf_get_colorspace">
|
||||
<return-type type="GdkColorspace" />
|
||||
</method>
|
||||
<method name="GetFormats" cname="gdk_pixbuf_get_formats" shared="true">
|
||||
<method name="GetFormats" cname="gdk_pixbuf_get_formats" shared="true" hidden="1">
|
||||
<return-type type="GSList*" />
|
||||
</method>
|
||||
<method name="GetFromDrawable" cname="gdk_pixbuf_get_from_drawable" library="libgdk-win32-2.0-0.dll">
|
||||
|
|
Loading…
Add table
Reference in a new issue