2008-06-16 Mike Kestner <mkestner@novell.com>
* glib/glue/object.c: fixes for object, boxed, and gtype property paramspec creation. Patch provided by Christian Hoff. svn path=/trunk/gtk-sharp/; revision=105905
This commit is contained in:
parent
bd2330adf2
commit
d46963e86b
2 changed files with 14 additions and 8 deletions
|
@ -1,3 +1,8 @@
|
|||
2008-06-16 Mike Kestner <mkestner@novell.com>
|
||||
|
||||
* glib/glue/object.c: fixes for object, boxed, and gtype
|
||||
property paramspec creation. Patch provided by Christian Hoff.
|
||||
|
||||
2008-06-09 Andrés G. Aragoneses <aaragoneses@novell.com>
|
||||
|
||||
* atk/Object.custom:
|
||||
|
|
|
@ -132,13 +132,14 @@ gtksharp_register_property(GType declaring_type, const gchar *name, const gchar
|
|||
case G_TYPE_POINTER:
|
||||
param_spec = g_param_spec_pointer (name, nick, blurb, flags);
|
||||
break;
|
||||
case G_TYPE_BOXED:
|
||||
param_spec = g_param_spec_boxed (name, nick, blurb, return_type, flags);
|
||||
break;
|
||||
case G_TYPE_OBJECT:
|
||||
param_spec = g_param_spec_object (name, nick, blurb, return_type, flags);
|
||||
break;
|
||||
default:
|
||||
if(return_type == G_TYPE_GTYPE)
|
||||
param_spec = g_param_spec_gtype (name, nick, blurb, G_TYPE_NONE, flags);
|
||||
else if(g_type_is_a (return_type, G_TYPE_BOXED))
|
||||
param_spec = g_param_spec_boxed (name, nick, blurb, return_type, flags);
|
||||
else if(g_type_is_a (return_type, G_TYPE_OBJECT))
|
||||
param_spec = g_param_spec_object (name, nick, blurb, return_type, flags);
|
||||
else
|
||||
// The property's return type is not supported
|
||||
return NULL;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue