diff --git a/ChangeLog b/ChangeLog index 393b8bfc9..134c38fcc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2002-03-28 Mike Kestner + + * generator/SignalHandler.cs : switch to 2.0 libs + * generator/SymbolTable.cs : switch to 2.0 libs + * glib/Object.cs : switch to 2.0 libs + * glib/SList.cs : switch to 2.0 libs + * glib/Value.cs : switch to 2.0 libs + * gtk/Application.cs : switch to 2.0 libs + 2002-03-26 Mike Kestner * generator/SignalHandler.cs : Use Path.DirectorySeparatorChar. diff --git a/generator/SignalHandler.cs b/generator/SignalHandler.cs index 88c3df67d..fa6608c61 100644 --- a/generator/SignalHandler.cs +++ b/generator/SignalHandler.cs @@ -149,7 +149,7 @@ namespace GtkSharp.Generation { } sw.WriteLine("\t\t}"); sw.WriteLine(); - sw.Write("\t\t[DllImport(\"gobject-1.3\", "); + sw.Write("\t\t[DllImport(\"gobject-2.0\", "); sw.WriteLine("CallingConvention=CallingConvention.Cdecl)]"); sw.Write("\t\tstatic extern void g_signal_connect_data("); sw.Write("IntPtr obj, String name, " + dname + " cb, int key, IntPtr p,"); diff --git a/generator/SymbolTable.cs b/generator/SymbolTable.cs index a268de347..82fab2ed7 100644 --- a/generator/SymbolTable.cs +++ b/generator/SymbolTable.cs @@ -66,10 +66,10 @@ namespace GtkSharp.Generation { simple_types.Add ("GParamSpec", "IntPtr"); dlls = new Hashtable(); - dlls.Add("Pango", "pango"); - dlls.Add("Atk", "atk"); - dlls.Add("Gdk", "gdk-x11-1.3"); - dlls.Add("Gtk", "gtk-x11-1.3"); + dlls.Add("Pango", "pango-1.0"); + dlls.Add("Atk", "atk-1.0"); + dlls.Add("Gdk", "gdk-x11-2.0"); + dlls.Add("Gtk", "gtk-x11-2.0"); } public void AddType (IGeneratable gen) diff --git a/generator/makefile b/generator/makefile index 31ecc0d8e..28343608f 100644 --- a/generator/makefile +++ b/generator/makefile @@ -4,7 +4,7 @@ all: @echo "'make unix' is broken for now." windows: - $(CSC) /unsafe /out:codegen.exe /recurse:*.cs + $(CSC) /unsafe /out:codegen.exe *.cs ./codegen gtkapi.xml linux: diff --git a/glib/Object.cs b/glib/Object.cs index ed8ec8952..e8917412a 100644 --- a/glib/Object.cs +++ b/glib/Object.cs @@ -197,7 +197,7 @@ namespace GLib { /// Accesses a string Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_get (IntPtr obj, string name, out string val, IntPtr term); @@ -214,7 +214,7 @@ namespace GLib { /// Accesses a boolean Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_get (IntPtr obj, string name, out bool val, IntPtr term); @@ -231,7 +231,7 @@ namespace GLib { /// Accesses a double Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_get (IntPtr obj, string name, out double val, IntPtr term); @@ -248,7 +248,7 @@ namespace GLib { /// Accesses a float Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_get (IntPtr obj, string name, out float val, IntPtr term); @@ -265,7 +265,7 @@ namespace GLib { /// Accesses an integer Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_get (IntPtr obj, string name, out int val, IntPtr term); @@ -282,7 +282,7 @@ namespace GLib { /// Accesses an unsigned integer Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_get (IntPtr obj, string name, out uint val, IntPtr term); @@ -299,7 +299,7 @@ namespace GLib { /// Accesses an Object Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_get (IntPtr obj, string name, out IntPtr val, IntPtr term); @@ -346,7 +346,7 @@ namespace GLib { /// Changes the value of a string Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_set (IntPtr obj, string name, string val, IntPtr term); @@ -363,7 +363,7 @@ namespace GLib { /// Changes the value of an integer Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_set (IntPtr obj, string name, int val, IntPtr term); @@ -380,7 +380,7 @@ namespace GLib { /// Changes the value of an unsigned integer Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_set (IntPtr obj, string name, uint val, IntPtr term); @@ -397,7 +397,7 @@ namespace GLib { /// Changes the value of a boolean Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_set (IntPtr obj, string name, bool val, IntPtr term); @@ -414,7 +414,7 @@ namespace GLib { /// Changes the value of a double Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_set (IntPtr obj, string name, double val, IntPtr term); @@ -431,7 +431,7 @@ namespace GLib { /// Changes the value of a float Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_set (IntPtr obj, string name, float val, IntPtr term); @@ -448,7 +448,7 @@ namespace GLib { /// Changes the value of an IntPtr Property. /// - [DllImport("gobject-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_object_set (IntPtr obj, string name, IntPtr val, IntPtr term); @@ -485,7 +485,7 @@ namespace GLib { /* - [DllImport("gtk-1.3")] + [DllImport("gtk-2.0")] static extern void g_object_set_data_full ( IntPtr obj, String key, diff --git a/glib/SList.cs b/glib/SList.cs index a71375581..b7a6dc6cd 100644 --- a/glib/SList.cs +++ b/glib/SList.cs @@ -65,7 +65,7 @@ namespace GLib { /// The number of elements in the SList. /// - [DllImport("glib-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("glib-2.0", CallingConvention=CallingConvention.Cdecl)] static extern int g_slist_length(IntPtr raw); public int Count { @@ -168,7 +168,7 @@ namespace GLib { /// Indexer to access members of the SList. /// - [DllImport("glib-1.3", CallingConvention=CallingConvention.Cdecl)] + [DllImport("glib-2.0", CallingConvention=CallingConvention.Cdecl)] static extern IntPtr g_slist_nth_data(IntPtr raw, int index); public object this[int index] { diff --git a/glib/Value.cs b/glib/Value.cs index b06552235..ccc44710a 100755 --- a/glib/Value.cs +++ b/glib/Value.cs @@ -26,7 +26,7 @@ namespace GLib { // Destructor is required since we are allocating unmananged // heap resources. - [DllImport("glib-1.3")] + [DllImport("glib-2.0")] static extern void g_free (IntPtr mem); ~Value () @@ -44,7 +44,7 @@ namespace GLib { /// value to it. /// - [DllImport("glib-1.3", + [DllImport("glib-2.0", CallingConvention=CallingConvention.Cdecl)] static extern IntPtr g_malloc0 (long n_bytes); @@ -74,7 +74,7 @@ namespace GLib { /// Constructs a Value from a specified boolean. /// - [DllImport("gobject-1.3", + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_value_set_boolean (IntPtr val, bool data); @@ -92,7 +92,7 @@ namespace GLib { /// Constructs a Value from a specified integer. /// - [DllImport("gobject-1.3", + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_value_set_int (IntPtr val, int data); @@ -110,7 +110,7 @@ namespace GLib { /// Constructs a Value from a specified string. /// - [DllImport("gobject-1.3", + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_value_set_string (IntPtr val, IntPtr data); @@ -129,7 +129,7 @@ namespace GLib { /// Prepares a raw value to hold a specified type. /// - [DllImport("gobject-1.3", + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern void g_value_init (IntPtr val, TypeFundamentals type); @@ -149,7 +149,7 @@ namespace GLib { /// boolean value. /// - [DllImport("gobject-1.3", + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern bool g_value_get_boolean (IntPtr val); @@ -170,7 +170,7 @@ namespace GLib { /// integer value. /// - [DllImport("gobject-1.3", + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern int g_value_get_int (IntPtr val); @@ -191,7 +191,7 @@ namespace GLib { /// string value. /// - [DllImport("gobject-1.3", + [DllImport("gobject-2.0", CallingConvention=CallingConvention.Cdecl)] static extern IntPtr g_value_get_string (IntPtr val); diff --git a/gtk/Application.cs b/gtk/Application.cs index e4009f88c..3f034ab2e 100755 --- a/gtk/Application.cs +++ b/gtk/Application.cs @@ -23,7 +23,7 @@ namespace Gtk { public class Application { - [DllImport("gtk-x11-1.3")] + [DllImport("gtk-x11-2.0")] static extern void gtk_init (int argc, IntPtr argv); public static void Init () @@ -31,7 +31,7 @@ namespace Gtk { gtk_init (0, new IntPtr(0)); } - [DllImport("gtk-x11-1.3")] + [DllImport("gtk-x11-2.0")] static extern void gtk_init (ref int argc, ref String[] argv); /// @@ -56,7 +56,7 @@ namespace Gtk { /// Begins the event loop iteration. /// - [DllImport("gtk-x11-1.3")] + [DllImport("gtk-x11-2.0")] static extern void gtk_main (); public static void Run () @@ -73,7 +73,7 @@ namespace Gtk { /// Terminates the event loop iteration. /// - [DllImport("gtk-x11-1.3")] + [DllImport("gtk-x11-2.0")] static extern void gtk_main_quit (); public static void Quit ()