2009-02-17 Christian Hoff <christian_hoff@gmx.net>

* sample/gtk-gio/MountOperation.cs:
	* gtk/Builder.custom:
	* glib/Value.cs: Resurrect build for MS .NET Framework

svn path=/trunk/gtk-sharp/; revision=127183
This commit is contained in:
Christian Hoff 2009-02-17 17:38:05 +00:00
parent 9a09de34cb
commit e91ff2bdad
4 changed files with 17 additions and 5 deletions

View file

@ -1,4 +1,9 @@
2009-02-06 Christian Hoff <christian_hoff@gmx.net>
2009-02-17 Christian Hoff <christian_hoff@gmx.net>
* sample/gtk-gio/MountOperation.cs:
* gtk/Builder.custom:
* glib/Value.cs: Resurrect build for MS .NET Framework
2009-02-06 Christian Hoff <christian_hoff@gmx.net>
* gtk/Gtk.metadata: Fix TreeModel.EmitRowsReordered signature

View file

@ -42,12 +42,14 @@ namespace GLib {
public Value (GLib.GType gtype)
{
type = IntPtr.Zero;
padding = new Padding ();
g_value_init (ref this, gtype.Val);
}
public Value (object obj)
{
type = IntPtr.Zero;
padding = new Padding ();
GType gtype = (GType) obj.GetType ();
g_value_init (ref this, gtype.Val);
@ -98,6 +100,7 @@ namespace GLib {
public Value (EnumWrapper wrap, string type_name)
{
type = IntPtr.Zero;
padding = new Padding ();
g_value_init (ref this, GType.FromName (type_name).Val);
if (wrap.flags)
g_value_set_flags (ref this, (uint) (int) wrap);
@ -130,6 +133,7 @@ namespace GLib {
public Value (Opaque val, string type_name)
{
type = IntPtr.Zero;
padding = new Padding ();
g_value_init (ref this, GType.FromName (type_name).Val);
g_value_set_boxed (ref this, val.Handle);
}
@ -147,6 +151,7 @@ namespace GLib {
public Value (GLib.Object obj, string prop_name)
{
type = IntPtr.Zero;
padding = new Padding ();
InitForProperty (obj, prop_name);
}
@ -154,6 +159,7 @@ namespace GLib {
public Value (GLib.Object obj, string prop_name, EnumWrapper wrap)
{
type = IntPtr.Zero;
padding = new Padding ();
InitForProperty (obj.NativeType, prop_name);
if (wrap.flags)
g_value_set_flags (ref this, (uint) (int) wrap);
@ -165,6 +171,7 @@ namespace GLib {
public Value (IntPtr obj, string prop_name, Opaque val)
{
type = IntPtr.Zero;
padding = new Padding ();
InitForProperty (GLib.Object.GetObject (obj), prop_name);
g_value_set_boxed (ref this, val.Handle);
}

View file

@ -230,7 +230,7 @@ class SignalConnector
static extern void gtk_builder_connect_signals_full(IntPtr raw, GtkSharp.BuilderConnectFuncNative func, IntPtr user_data);
public void ConnectSignals() {
GtkSharp.BuilderConnectFuncWrapper func_wrapper = new GtkSharp.BuilderConnectFuncWrapper (ConnectFunc);
GtkSharp.BuilderConnectFuncWrapper func_wrapper = new GtkSharp.BuilderConnectFuncWrapper (new BuilderConnectFunc (ConnectFunc));
gtk_builder_connect_signals_full(builder.Handle, func_wrapper.NativeDelegate, IntPtr.Zero);
}
@ -243,7 +243,7 @@ class SignalConnector
| System.Reflection.BindingFlags.Static
| System.Reflection.BindingFlags.Public
| System.Reflection.BindingFlags.NonPublic,
SignalFilter, signal_name);
new System.Reflection.MemberFilter (SignalFilter), signal_name);
foreach (System.Reflection.EventInfo ei in evnts) {
bool connected = false;
System.Reflection.MethodInfo add = ei.GetAddMethod ();

View file

@ -46,7 +46,7 @@ public class TestMount
Window w = new Window ("test");
operation = new Gtk.MountOperation (w);
Button b = new Button ("Mount");
b.Clicked += HandleButtonClicked;
b.Clicked += new EventHandler (HandleButtonClicked);
b.Show ();
w.Add (b);
w.Show ();
@ -56,7 +56,7 @@ public class TestMount
static void HandleButtonClicked (object sender, EventArgs args)
{
System.Console.WriteLine ("clicked");
file.MountEnclosingVolume (0, operation, null, HandleMountFinished);
file.MountEnclosingVolume (0, operation, null, new GLib.AsyncReadyCallback (HandleMountFinished));
}
static void HandleMountFinished (GLib.Object sender, GLib.AsyncResult result)