mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2025-05-13 05:52:12 +00:00
2008-05-22 Mike Kestner <mkestner@novell.com>
* gtk/Widget.custom: guard against MissingIntPtrCtorException in the Activate and SetScrollAdjustments funky signal VM impl. Can't use SignalClosure easily. Could be reworked more cleanly at some point. Or not. svn path=/trunk/gtk-sharp/; revision=103827
This commit is contained in:
parent
a1473c0b58
commit
d9721b63dc
|
@ -1,3 +1,10 @@
|
||||||
|
2008-05-22 Mike Kestner <mkestner@novell.com>
|
||||||
|
|
||||||
|
* gtk/Widget.custom: guard against MissingIntPtrCtorException in
|
||||||
|
the Activate and SetScrollAdjustments funky signal VM impl. Can't
|
||||||
|
use SignalClosure easily. Could be reworked more cleanly at some
|
||||||
|
point. Or not.
|
||||||
|
|
||||||
2008-05-21 Mike Kestner <mkestner@novell.com>
|
2008-05-21 Mike Kestner <mkestner@novell.com>
|
||||||
|
|
||||||
* gtk/Object.custom (OnDestroyed): ensure Dispose runs even if
|
* gtk/Object.custom (OnDestroyed): ensure Dispose runs even if
|
||||||
|
|
|
@ -201,7 +201,12 @@ static SetScrollAdjustmentsDelegate SetScrollAdjustmentsCallback;
|
||||||
static void SetScrollAdjustments_cb (IntPtr widget, IntPtr hadj, IntPtr vadj)
|
static void SetScrollAdjustments_cb (IntPtr widget, IntPtr hadj, IntPtr vadj)
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
Widget obj = GLib.Object.GetObject (widget, false) as Widget;
|
Widget obj;
|
||||||
|
try {
|
||||||
|
obj = GLib.Object.GetObject (widget, false) as Widget;
|
||||||
|
} catch (GLib.MissingIntPtrCtorException) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
Gtk.Adjustment h = GLib.Object.GetObject (hadj, false) as Gtk.Adjustment;
|
Gtk.Adjustment h = GLib.Object.GetObject (hadj, false) as Gtk.Adjustment;
|
||||||
Gtk.Adjustment v = GLib.Object.GetObject (vadj, false) as Gtk.Adjustment;
|
Gtk.Adjustment v = GLib.Object.GetObject (vadj, false) as Gtk.Adjustment;
|
||||||
obj.OnSetScrollAdjustments (h, v);
|
obj.OnSetScrollAdjustments (h, v);
|
||||||
|
@ -232,8 +237,17 @@ static ActivateDelegate ActivateCallback;
|
||||||
|
|
||||||
static void Activate_cb (IntPtr widget)
|
static void Activate_cb (IntPtr widget)
|
||||||
{
|
{
|
||||||
Widget obj = GLib.Object.GetObject (widget, false) as Widget;
|
try {
|
||||||
obj.OnActivate ();
|
Widget obj;
|
||||||
|
try {
|
||||||
|
obj = GLib.Object.GetObject (widget, false) as Widget;
|
||||||
|
} catch (GLib.MissingIntPtrCtorException) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
obj.OnActivate ();
|
||||||
|
} catch (Exception e) {
|
||||||
|
GLib.ExceptionManager.RaiseUnhandledException (e, false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void ConnectActivate (GLib.GType gtype)
|
static void ConnectActivate (GLib.GType gtype)
|
||||||
|
|
Loading…
Reference in a new issue