mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2024-09-09 00:13:20 +02:00
2009-04-21 Christian Hoff <christian_hoff@gmx.net>
* glib/Value.cs: Fixes for fundamental GType support. Patch provided by Sebastian Dröge. svn path=/trunk/gtk-sharp/; revision=132225
This commit is contained in:
parent
37c1f46d17
commit
643a910cd6
@ -1,3 +1,8 @@
|
|||||||
|
2009-04-21 Christian Hoff <christian_hoff@gmx.net>
|
||||||
|
|
||||||
|
* glib/Value.cs: Fixes for fundamental GType support. Patch
|
||||||
|
provided by Sebastian Dröge.
|
||||||
|
|
||||||
2009-04-21 Christian Hoff <christian_hoff@gmx.net>
|
2009-04-21 Christian Hoff <christian_hoff@gmx.net>
|
||||||
|
|
||||||
* gtk/Widget.custom: Deglued implementation of StyleGetProperty.
|
* gtk/Widget.custom: Deglued implementation of StyleGetProperty.
|
||||||
|
@ -346,7 +346,8 @@ namespace GLib {
|
|||||||
while (ci == null && t != null) {
|
while (ci == null && t != null) {
|
||||||
if (!t.IsAbstract)
|
if (!t.IsAbstract)
|
||||||
ci = t.GetConstructor (new Type[] { typeof (GLib.Value) });
|
ci = t.GetConstructor (new Type[] { typeof (GLib.Value) });
|
||||||
t = t.BaseType;
|
if (ci == null)
|
||||||
|
t = t.BaseType;
|
||||||
}
|
}
|
||||||
} catch (Exception) {
|
} catch (Exception) {
|
||||||
ci = null;
|
ci = null;
|
||||||
@ -364,10 +365,11 @@ namespace GLib {
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
while (mi == null && t != null) {
|
while (mi == null && t != null) {
|
||||||
mi = t.GetMethod ("SetGValue", new Type[] { typeof (GLib.Value) });
|
mi = t.GetMethod ("SetGValue", new Type[] { Type.GetType ("GLib.Value&") });
|
||||||
if (mi.IsAbstract)
|
if (mi != null && (mi.IsAbstract || mi.ReturnType != typeof (void)))
|
||||||
mi = null;
|
mi = null;
|
||||||
t = t.BaseType;
|
if (mi == null)
|
||||||
|
t = t.BaseType;
|
||||||
}
|
}
|
||||||
} catch (Exception) {
|
} catch (Exception) {
|
||||||
mi = null;
|
mi = null;
|
||||||
@ -376,7 +378,9 @@ namespace GLib {
|
|||||||
if (mi == null)
|
if (mi == null)
|
||||||
throw new Exception ("Unknown type " + new GType (type).ToString ());
|
throw new Exception ("Unknown type " + new GType (type).ToString ());
|
||||||
|
|
||||||
mi.Invoke (val, new object[] { this });
|
object[] parameters = new object[] { this };
|
||||||
|
mi.Invoke (val, parameters);
|
||||||
|
this = (GLib.Value) parameters[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
object ToBoxed ()
|
object ToBoxed ()
|
||||||
|
Loading…
Reference in New Issue
Block a user