diff options
author | Corentin Noël <corentin@elementary.io> | 2019-06-18 07:31:45 +0000 |
---|---|---|
committer | Alberto Fanjul <albertofanjul@gmail.com> | 2019-06-18 07:31:45 +0000 |
commit | a543e99069b693d96e68eb8e00a2dce00a1946a7 (patch) | |
tree | af1f0429370af555ca4ff0f7d67e06c4dbdfb8ef /plugins | |
parent | 91a8b096a745194d27b3bf27d6b20ef7440e766d (diff) | |
download | glade-a543e99069b693d96e68eb8e00a2dce00a1946a7.tar.gz |
Rename GladePropertyClass to GladePropertyDef and declare it as boxed
Diffstat (limited to 'plugins')
29 files changed, 174 insertions, 174 deletions
diff --git a/plugins/gtk+/glade-accels.c b/plugins/gtk+/glade-accels.c index 71bfc4d7..cb0c4308 100644 --- a/plugins/gtk+/glade-accels.c +++ b/plugins/gtk+/glade-accels.c @@ -202,9 +202,9 @@ glade_eprop_accel_populate_view (GladeEditorProperty * eprop, { GladeEPropAccel *eprop_accel = GLADE_EPROP_ACCEL (eprop); GladeSignalDef *sdef; - GladePropertyClass *pclass = glade_editor_property_get_pclass (eprop); + GladePropertyDef *pdef = glade_editor_property_get_property_def (eprop); GladeProperty *property = glade_editor_property_get_property (eprop); - GladeWidgetAdaptor *adaptor = glade_property_class_get_adaptor (pclass); + GladeWidgetAdaptor *adaptor = glade_property_def_get_adaptor (pdef); GtkTreeStore *model = (GtkTreeStore *) gtk_tree_view_get_model (view); GtkTreeIter iter; GladeEpropIterTab *parent_tab; @@ -343,15 +343,15 @@ accel_edited (GtkCellRendererAccel * accel, gboolean key_was_set; GtkTreeIter iter, parent_iter, new_iter; gchar *accel_text; - GladePropertyClass *pclass; + GladePropertyDef *pdef; GladeWidgetAdaptor *adaptor; gboolean is_action; G_GNUC_BEGIN_IGNORE_DEPRECATIONS GType type_action = GTK_TYPE_ACTION; G_GNUC_END_IGNORE_DEPRECATIONS - pclass = glade_editor_property_get_pclass (GLADE_EDITOR_PROPERTY (eprop_accel)); - adaptor = glade_property_class_get_adaptor (pclass); + pdef = glade_editor_property_get_property_def (GLADE_EDITOR_PROPERTY (eprop_accel)); + adaptor = glade_property_def_get_adaptor (pdef); if (!gtk_tree_model_get_iter_from_string (eprop_accel->model, &iter, path_string)) diff --git a/plugins/gtk+/glade-cell-renderer-editor.c b/plugins/gtk+/glade-cell-renderer-editor.c index bec12d8e..23df948e 100644 --- a/plugins/gtk+/glade-cell-renderer-editor.c +++ b/plugins/gtk+/glade-cell-renderer-editor.c @@ -41,9 +41,9 @@ typedef struct GladeCellRendererEditor *editor; GtkWidget *attributes_check; - GladePropertyClass *pclass; - GladePropertyClass *attr_pclass; - GladePropertyClass *use_attr_pclass; + GladePropertyDef *pdef; + GladePropertyDef *attr_pdef; + GladePropertyDef *use_attr_pdef; GtkWidget *use_prop_label; GtkWidget *use_attr_label; @@ -101,7 +101,7 @@ glade_cell_renderer_editor_load (GladeEditable * editable, GladeWidget * widget) CheckTab *tab = l->data; gboolean use_attr = FALSE; - glade_widget_property_get (widget, glade_property_class_id (tab->use_attr_pclass), &use_attr); + glade_widget_property_get (widget, glade_property_def_id (tab->use_attr_pdef), &use_attr); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (tab->attributes_check), use_attr); if (use_attr) @@ -190,17 +190,17 @@ attributes_toggled (GtkWidget * widget, CheckTab * tab) glade_command_push_group (_("Setting %s to use the %s property as an attribute"), glade_widget_get_name (gwidget), - glade_property_class_id (tab->pclass)); + glade_property_def_id (tab->pdef)); property = - glade_widget_get_property (gwidget, glade_property_class_id (tab->pclass)); + glade_widget_get_property (gwidget, glade_property_def_id (tab->pdef)); glade_property_get_default (property, &value); glade_command_set_property_value (property, &value); g_value_unset (&value); property = - glade_widget_get_property (gwidget, glade_property_class_id (tab->use_attr_pclass)); + glade_widget_get_property (gwidget, glade_property_def_id (tab->use_attr_pdef)); glade_command_set_property (property, TRUE); glade_command_pop_group (); @@ -211,16 +211,16 @@ attributes_toggled (GtkWidget * widget, CheckTab * tab) { glade_command_push_group (_("Setting %s to use the %s property directly"), glade_widget_get_name (gwidget), - glade_property_class_id (tab->pclass)); + glade_property_def_id (tab->pdef)); property = - glade_widget_get_property (gwidget, glade_property_class_id (tab->attr_pclass)); + glade_widget_get_property (gwidget, glade_property_def_id (tab->attr_pdef)); glade_property_get_default (property, &value); glade_command_set_property_value (property, &value); g_value_unset (&value); property = - glade_widget_get_property (gwidget, glade_property_class_id (tab->use_attr_pclass)); + glade_widget_get_property (gwidget, glade_property_def_id (tab->use_attr_pdef)); glade_command_set_property (property, FALSE); glade_command_pop_group (); @@ -233,17 +233,17 @@ attributes_toggled (GtkWidget * widget, CheckTab * tab) } static gint -property_class_comp (gconstpointer a, gconstpointer b) +property_def_comp (gconstpointer a, gconstpointer b) { - GladePropertyClass *ca = (GladePropertyClass *)a, *cb = (GladePropertyClass *)b; + GladePropertyDef *ca = (GladePropertyDef *)a, *cb = (GladePropertyDef *)b; GParamSpec *pa, *pb; - pa = glade_property_class_get_pspec (ca); - pb = glade_property_class_get_pspec (cb); + pa = glade_property_def_get_pspec (ca); + pb = glade_property_def_get_pspec (cb); if (pa->owner_type == pb->owner_type) { - gdouble result = glade_property_class_weight (ca) - glade_property_class_weight (cb); + gdouble result = glade_property_def_weight (ca) - glade_property_def_weight (cb); /* Avoid cast to int */ if (result < 0.0) return -1; @@ -255,9 +255,9 @@ property_class_comp (gconstpointer a, gconstpointer b) else { if (g_type_is_a (pa->owner_type, pb->owner_type)) - return (glade_property_class_common (ca) || glade_property_class_get_is_packing (ca)) ? 1 : -1; + return (glade_property_def_common (ca) || glade_property_def_get_is_packing (ca)) ? 1 : -1; else - return (glade_property_class_common (ca) || glade_property_class_get_is_packing (ca)) ? -1 : 1; + return (glade_property_def_common (ca) || glade_property_def_get_is_packing (ca)) ? -1 : 1; } } @@ -269,15 +269,15 @@ get_sorted_properties (GladeWidgetAdaptor * adaptor, GladeEditorPageType type) for (l = glade_widget_adaptor_get_properties (adaptor); l; l = l->next) { - GladePropertyClass *klass = l->data; + GladePropertyDef *def = l->data; - if (GLADE_PROPERTY_CLASS_IS_TYPE (klass, type) && - (glade_property_class_is_visible (klass))) + if (GLADE_PROPERTY_DEF_IS_TYPE (def, type) && + (glade_property_def_is_visible (def))) { - list = g_list_prepend (list, klass); + list = g_list_prepend (list, def); } } - return g_list_sort (list, property_class_comp); + return g_list_sort (list, property_def_comp); } @@ -287,7 +287,7 @@ glade_cell_renderer_editor_new (GladeWidgetAdaptor * adaptor, { GladeCellRendererEditor *renderer_editor; GladeEditorProperty *eprop; - GladePropertyClass *pclass, *attr_pclass, *use_attr_pclass; + GladePropertyDef *pdef, *attr_pdef, *use_attr_pdef; GList *list, *sorted; GtkWidget *hbox_left, *hbox_right, *grid; gchar *str; @@ -320,32 +320,32 @@ glade_cell_renderer_editor_new (GladeWidgetAdaptor * adaptor, gchar *attr_name; gchar *use_attr_name; - pclass = list->data; + pdef = list->data; /* "stock-size" is a normal property, but we virtualize it to use the GtkIconSize enumeration */ - if (glade_property_class_get_virtual (pclass) && - strcmp (glade_property_class_id (pclass), "stock-size") != 0) + if (glade_property_def_get_virtual (pdef) && + strcmp (glade_property_def_id (pdef), "stock-size") != 0) continue; - attr_name = g_strdup_printf ("attr-%s", glade_property_class_id (pclass)); - use_attr_name = g_strdup_printf ("use-attr-%s", glade_property_class_id (pclass)); + attr_name = g_strdup_printf ("attr-%s", glade_property_def_id (pdef)); + use_attr_name = g_strdup_printf ("use-attr-%s", glade_property_def_id (pdef)); - attr_pclass = - glade_widget_adaptor_get_property_class (adaptor, attr_name); - use_attr_pclass = - glade_widget_adaptor_get_property_class (adaptor, use_attr_name); + attr_pdef = + glade_widget_adaptor_get_property_def (adaptor, attr_name); + use_attr_pdef = + glade_widget_adaptor_get_property_def (adaptor, use_attr_name); - if (attr_pclass && use_attr_pclass) + if (attr_pdef && use_attr_pdef) { CheckTab *tab = g_new0 (CheckTab, 1); GParamSpec *pspec; - pspec = glade_property_class_get_pspec (pclass); + pspec = glade_property_def_get_pspec (pdef); tab->editor = renderer_editor; - tab->pclass = pclass; - tab->attr_pclass = attr_pclass; - tab->use_attr_pclass = use_attr_pclass; + tab->pdef = pdef; + tab->attr_pdef = attr_pdef; + tab->use_attr_pdef = use_attr_pdef; /* Label appearance... */ hbox_left = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0); @@ -354,7 +354,7 @@ glade_cell_renderer_editor_new (GladeWidgetAdaptor * adaptor, tab->attributes_check = gtk_check_button_new (); str = g_strdup_printf (_("Retrieve %s from model (type %s)"), - glade_property_class_get_name (pclass), + glade_property_def_get_name (pdef), g_type_name (pspec->value_type)); gtk_widget_set_tooltip_text (tab->attributes_check, str); g_free (str); @@ -363,7 +363,7 @@ glade_cell_renderer_editor_new (GladeWidgetAdaptor * adaptor, FALSE, 4); /* Edit property */ - eprop = glade_widget_adaptor_create_eprop (adaptor, pclass, TRUE); + eprop = glade_widget_adaptor_create_eprop (adaptor, pdef, TRUE); gtk_box_pack_start (GTK_BOX (hbox_left), glade_editor_property_get_item_label (eprop), TRUE, TRUE, 4); gtk_box_pack_start (GTK_BOX (hbox_right), GTK_WIDGET (eprop), FALSE, @@ -376,7 +376,7 @@ glade_cell_renderer_editor_new (GladeWidgetAdaptor * adaptor, /* Edit attribute */ eprop = - glade_widget_adaptor_create_eprop (adaptor, attr_pclass, TRUE); + glade_widget_adaptor_create_eprop (adaptor, attr_pdef, TRUE); gtk_box_pack_start (GTK_BOX (hbox_right), GTK_WIDGET (eprop), FALSE, FALSE, 4); renderer_editor->properties = @@ -584,7 +584,7 @@ glade_eprop_cell_attribute_create_input (GladeEditorProperty * eprop) hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 2); - adjustment = glade_property_class_make_adjustment (glade_editor_property_get_pclass (eprop)); + adjustment = glade_property_def_make_adjustment (glade_editor_property_get_property_def (eprop)); eprop_attribute->spin = gtk_spin_button_new (adjustment, 1.0, 0); eprop_attribute->columns = diff --git a/plugins/gtk+/glade-column-types.c b/plugins/gtk+/glade-column-types.c index 38df1330..7daf767d 100644 --- a/plugins/gtk+/glade-column-types.c +++ b/plugins/gtk+/glade-column-types.c @@ -61,13 +61,13 @@ column_types_store_populate_enums_flags (GtkListStore * store, gboolean enums) for (list = adaptors; list; list = list->next) { GladeWidgetAdaptor *adaptor = list->data; - GladePropertyClass *pclass; + GladePropertyDef *pdef; GParamSpec *pspec; for (l = glade_widget_adaptor_get_properties (adaptor); l; l = l->next) { - pclass = l->data; - pspec = glade_property_class_get_pspec (pclass); + pdef = l->data; + pspec = glade_property_def_get_pspec (pdef); /* special case out a few of these... */ if (strcmp (g_type_name (pspec->value_type), diff --git a/plugins/gtk+/glade-eprop-enum-int.c b/plugins/gtk+/glade-eprop-enum-int.c index be281c94..29ece34f 100644 --- a/plugins/gtk+/glade-eprop-enum-int.c +++ b/plugins/gtk+/glade-eprop-enum-int.c @@ -429,13 +429,13 @@ glade_eprop_enum_int_set_property (GObject *object, } GladeEditorProperty * -glade_eprop_enum_int_new (GladePropertyClass *pclass, +glade_eprop_enum_int_new (GladePropertyDef *pdef, GType type, gboolean use_command) { GladeEditorProperty *eprop = g_object_new (GLADE_TYPE_EPROP_ENUM_INT, - "property-class", pclass, + "property-def", pdef, "use-command", use_command, "type", type, NULL); diff --git a/plugins/gtk+/glade-eprop-enum-int.h b/plugins/gtk+/glade-eprop-enum-int.h index dcf63386..b119db8e 100644 --- a/plugins/gtk+/glade-eprop-enum-int.h +++ b/plugins/gtk+/glade-eprop-enum-int.h @@ -22,9 +22,9 @@ typedef struct { GladeEditorPropertyClass eprop_class; } GladeEPropEnumIntClass; -GladeEditorProperty *glade_eprop_enum_int_new (GladePropertyClass *pclass, - GType type, - gboolean use_command); +GladeEditorProperty *glade_eprop_enum_int_new (GladePropertyDef *pdef, + GType type, + gboolean use_command); G_END_DECLS diff --git a/plugins/gtk+/glade-gtk-action-widgets.c b/plugins/gtk+/glade-gtk-action-widgets.c index 7cbdff95..47e8db0d 100644 --- a/plugins/gtk+/glade-gtk-action-widgets.c +++ b/plugins/gtk+/glade-gtk-action-widgets.c @@ -128,7 +128,7 @@ glade_gtk_action_widgets_write_responses (GladeWidget *widget, glade_xml_node_append_child (node, widget_node); str = - glade_property_class_make_string_from_gvalue (glade_property_get_class (property), + glade_property_def_make_string_from_gvalue (glade_property_get_def (property), glade_property_inline_value (property)); glade_xml_node_set_property_string (widget_node, GLADE_TAG_RESPONSE, str); diff --git a/plugins/gtk+/glade-gtk-adjustment.c b/plugins/gtk+/glade-gtk-adjustment.c index 44ce9bfd..a7a16561 100644 --- a/plugins/gtk+/glade-gtk-adjustment.c +++ b/plugins/gtk+/glade-gtk-adjustment.c @@ -71,8 +71,8 @@ static gint get_prop_precision (GladeWidget *widget, gchar *property) { GladeProperty *prop = glade_widget_get_property (widget, property); - GladePropertyClass *klass = glade_property_get_class (prop); - GParamSpec *pspec = glade_property_class_get_pspec (klass); + GladePropertyDef *def = glade_property_get_def (prop); + GParamSpec *pspec = glade_property_def_get_pspec (def); GValue value = G_VALUE_INIT; glade_property_get_value (prop, &value); diff --git a/plugins/gtk+/glade-gtk-button.c b/plugins/gtk+/glade-gtk-button.c index b4e87d16..f5e691e9 100644 --- a/plugins/gtk+/glade-gtk-button.c +++ b/plugins/gtk+/glade-gtk-button.c @@ -188,8 +188,8 @@ glade_gtk_button_post_create (GladeWidgetAdaptor *adaptor, static inline gboolean glade_gtk_lock_button_is_own_property (GladeProperty *property) { - GladePropertyClass *klass = glade_property_get_class (property); - GParamSpec *spec = glade_property_class_get_pspec (klass); + GladePropertyDef *def = glade_property_get_def (property); + GParamSpec *spec = glade_property_def_get_pspec (def); return (spec->owner_type == GTK_TYPE_LOCK_BUTTON); } @@ -238,7 +238,7 @@ glade_gtk_button_set_property (GladeWidgetAdaptor *adaptor, id, value); glade_gtk_sync_use_appearance (widget); } - else if (GPC_VERSION_CHECK (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + else if (GPC_VERSION_CHECK (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, id, value); /* GtkLockButton hides itself after setting a property so we need to make sure @@ -327,18 +327,18 @@ glade_gtk_button_write_widget (GladeWidgetAdaptor *adaptor, GladeEditorProperty * glade_gtk_button_create_eprop (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, gboolean use_command) { GladeEditorProperty *eprop; - if (strcmp (glade_property_class_id(klass), "response-id")==0) + if (strcmp (glade_property_def_id(def), "response-id")==0) { - eprop = glade_eprop_enum_int_new (klass, GTK_TYPE_RESPONSE_TYPE, use_command); + eprop = glade_eprop_enum_int_new (def, GTK_TYPE_RESPONSE_TYPE, use_command); } else eprop = GWA_GET_CLASS - (GTK_TYPE_WIDGET)->create_eprop (adaptor, klass, use_command); + (GTK_TYPE_WIDGET)->create_eprop (adaptor, def, use_command); return eprop; } diff --git a/plugins/gtk+/glade-gtk-cell-layout.c b/plugins/gtk+/glade-gtk-cell-layout.c index 0ee762a7..80469a2a 100644 --- a/plugins/gtk+/glade-gtk-cell-layout.c +++ b/plugins/gtk+/glade-gtk-cell-layout.c @@ -262,7 +262,7 @@ glade_gtk_cell_renderer_write_attributes (GladeWidget *widget, GladeXmlNode *node) { GladeProperty *property; - GladePropertyClass *pclass; + GladePropertyDef *pdef; GladeXmlNode *attrs_node; gchar *attr_name; GList *l; @@ -276,22 +276,22 @@ glade_gtk_cell_renderer_write_attributes (GladeWidget *widget, for (l = glade_widget_get_properties (widget); l; l = l->next) { property = l->data; - pclass = glade_property_get_class (property); + pdef = glade_property_get_def (property); - if (strncmp (glade_property_class_id (pclass), "attr-", attr_len) == 0) + if (strncmp (glade_property_def_id (pdef), "attr-", attr_len) == 0) { GladeXmlNode *attr_node; gchar *column_str, *use_attr_str; gboolean use_attr = FALSE; - use_attr_str = g_strdup_printf ("use-%s", glade_property_class_id (pclass)); + use_attr_str = g_strdup_printf ("use-%s", glade_property_def_id (pdef)); glade_widget_property_get (widget, use_attr_str, &use_attr); if (use_attr && g_value_get_int (glade_property_inline_value (property)) >= 0) { column_str = g_strdup_printf ("%d", g_value_get_int (glade_property_inline_value (property))); - attr_name = (gchar *)&glade_property_class_id (pclass)[attr_len]; + attr_name = (gchar *)&glade_property_def_id (pdef)[attr_len]; attr_node = glade_xml_node_new (context, GLADE_TAG_ATTRIBUTE); glade_xml_node_append_child (attrs_node, attr_node); diff --git a/plugins/gtk+/glade-gtk-cell-renderer.c b/plugins/gtk+/glade-gtk-cell-renderer.c index 38fcb7d0..ee0ffdff 100644 --- a/plugins/gtk+/glade-gtk-cell-renderer.c +++ b/plugins/gtk+/glade-gtk-cell-renderer.c @@ -60,7 +60,7 @@ glade_gtk_cell_renderer_deep_post_create (GladeWidgetAdaptor *adaptor, GObject *object, GladeCreateReason reason) { - GladePropertyClass *pclass; + GladePropertyDef *pdef; GladeProperty *property; GladeWidget *widget; const GList *l; @@ -69,11 +69,11 @@ glade_gtk_cell_renderer_deep_post_create (GladeWidgetAdaptor *adaptor, for (l = glade_widget_adaptor_get_properties (adaptor); l; l = l->next) { - pclass = l->data; + pdef = l->data; - if (strncmp (glade_property_class_id (pclass), "use-attr-", strlen ("use-attr-")) == 0) + if (strncmp (glade_property_def_id (pdef), "use-attr-", strlen ("use-attr-")) == 0) { - property = glade_widget_get_property (widget, glade_property_class_id (pclass)); + property = glade_widget_get_property (widget, glade_property_def_id (pdef)); glade_property_sync (property); } } @@ -83,18 +83,18 @@ glade_gtk_cell_renderer_deep_post_create (GladeWidgetAdaptor *adaptor, GladeEditorProperty * glade_gtk_cell_renderer_create_eprop (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, gboolean use_command) { GladeEditorProperty *eprop; - if (strncmp (glade_property_class_id (klass), "attr-", strlen ("attr-")) == 0) + if (strncmp (glade_property_def_id (def), "attr-", strlen ("attr-")) == 0) eprop = g_object_new (GLADE_TYPE_EPROP_CELL_ATTRIBUTE, - "property-class", klass, + "property-def", def, "use-command", use_command, NULL); else eprop = GWA_GET_CLASS - (G_TYPE_OBJECT)->create_eprop (adaptor, klass, use_command); + (G_TYPE_OBJECT)->create_eprop (adaptor, def, use_command); return eprop; } @@ -212,7 +212,7 @@ glade_gtk_cell_renderer_write_properties (GladeWidget *widget, GladeXmlNode *node) { GladeProperty *property, *prop; - GladePropertyClass *pclass; + GladePropertyDef *pdef; gchar *attr_name; GList *l; static gint attr_len = 0; @@ -223,17 +223,17 @@ glade_gtk_cell_renderer_write_properties (GladeWidget *widget, for (l = glade_widget_get_properties (widget); l; l = l->next) { property = l->data; - pclass = glade_property_get_class (property); + pdef = glade_property_get_def (property); - if (strncmp (glade_property_class_id (pclass), "attr-", attr_len) == 0) + if (strncmp (glade_property_def_id (pdef), "attr-", attr_len) == 0) { gchar *use_attr_str; gboolean use_attr = FALSE; - use_attr_str = g_strdup_printf ("use-%s", glade_property_class_id (pclass)); + use_attr_str = g_strdup_printf ("use-%s", glade_property_def_id (pdef)); glade_widget_property_get (widget, use_attr_str, &use_attr); - attr_name = (gchar *)&glade_property_class_id (pclass)[attr_len]; + attr_name = (gchar *)&glade_property_def_id (pdef)[attr_len]; prop = glade_widget_get_property (widget, attr_name); if (!use_attr && prop) @@ -290,16 +290,16 @@ glade_gtk_cell_renderer_parse_finished (GladeProject *project, for (l = glade_widget_get_properties (widget); l; l = l->next) { GladeProperty *switch_prop; - GladePropertyClass *pclass; + GladePropertyDef *pdef; property = l->data; - pclass = glade_property_get_class (property); + pdef = glade_property_get_def (property); - if (strncmp (glade_property_class_id (pclass), "attr-", attr_len) != 0 && - strncmp (glade_property_class_id (pclass), "use-attr-", use_attr_len) != 0 && + if (strncmp (glade_property_def_id (pdef), "attr-", attr_len) != 0 && + strncmp (glade_property_def_id (pdef), "use-attr-", use_attr_len) != 0 && (switch_prop = glade_gtk_cell_renderer_attribute_switch (widget, - glade_property_class_id (pclass))) != NULL) + glade_property_def_id (pdef))) != NULL) { if (glade_property_original_default (property)) glade_property_set (switch_prop, TRUE); @@ -350,7 +350,7 @@ glade_gtk_cell_renderer_sync_attributes (GObject *object) GladeWidget *parent; GladeWidget *gmodel; GladeProperty *property; - GladePropertyClass *pclass; + GladePropertyDef *pdef; gchar *attr_prop_name; GList *l, *column_list = NULL; gint columns = 0; @@ -386,20 +386,20 @@ glade_gtk_cell_renderer_sync_attributes (GObject *object) for (l = glade_widget_get_properties (widget); l; l = l->next) { property = l->data; - pclass = glade_property_get_class (property); + pdef = glade_property_get_def (property); - if (strncmp (glade_property_class_id (pclass), "attr-", attr_len) == 0) + if (strncmp (glade_property_def_id (pdef), "attr-", attr_len) == 0) { gint column = g_value_get_int (glade_property_inline_value (property)); - attr_prop_name = (gchar *)&glade_property_class_id (pclass)[attr_len]; + attr_prop_name = (gchar *)&glade_property_def_id (pdef)[attr_len]; if (column >= 0 && column < columns) { GladeColumnType *column_type = (GladeColumnType *) g_list_nth_data (column_list, column); GType column_gtype = g_type_from_name (column_type->type_name); - GParamSpec *pspec = glade_property_class_get_pspec (pclass); + GParamSpec *pspec = glade_property_def_get_pspec (pdef); if (column_gtype && g_value_type_transformable (column_gtype, pspec->value_type)) diff --git a/plugins/gtk+/glade-gtk-combo-box-text.c b/plugins/gtk+/glade-gtk-combo-box-text.c index d1aed871..99548462 100644 --- a/plugins/gtk+/glade-gtk-combo-box-text.c +++ b/plugins/gtk+/glade-gtk-combo-box-text.c @@ -60,33 +60,33 @@ glade_gtk_combo_box_text_post_create (GladeWidgetAdaptor *adaptor, GladeEditorProperty * glade_gtk_combo_box_text_create_eprop (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, - gboolean use_command) + GladePropertyDef *def, + gboolean use_command) { GladeEditorProperty *eprop; GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_STRING_LIST) { - eprop = glade_eprop_string_list_new (klass, use_command, TRUE, TRUE); + eprop = glade_eprop_string_list_new (def, use_command, TRUE, TRUE); } else eprop = GWA_GET_CLASS - (GTK_TYPE_WIDGET)->create_eprop (adaptor, klass, use_command); + (GTK_TYPE_WIDGET)->create_eprop (adaptor, def, use_command); return eprop; } gchar * glade_gtk_combo_box_text_string_from_value (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, const GValue *value) { GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_STRING_LIST) { @@ -96,7 +96,7 @@ glade_gtk_combo_box_text_string_from_value (GladeWidgetAdaptor *adaptor, } else return GWA_GET_CLASS - (GTK_TYPE_COMBO_BOX)->string_from_value (adaptor, klass, value); + (GTK_TYPE_COMBO_BOX)->string_from_value (adaptor, def, value); } void diff --git a/plugins/gtk+/glade-gtk-container.c b/plugins/gtk+/glade-gtk-container.c index 50d600ca..3066884f 100644 --- a/plugins/gtk+/glade-gtk-container.c +++ b/plugins/gtk+/glade-gtk-container.c @@ -103,7 +103,7 @@ glade_gtk_container_replace_child (GladeWidgetAdaptor *adaptor, GtkWidget *new_widget) { GParamSpec **param_spec; - GladePropertyClass *pclass; + GladePropertyDef *pdef; GValue *value; guint nproperties; guint i; @@ -134,10 +134,10 @@ glade_gtk_container_replace_child (GladeWidgetAdaptor *adaptor, */ if (GLADE_IS_PLACEHOLDER (new_widget)) { - pclass = glade_widget_adaptor_get_pack_property_class + pdef = glade_widget_adaptor_get_pack_property_def (adaptor, param_spec[i]->name); - if (pclass && glade_property_class_transfer_on_paste (pclass)) + if (pdef && glade_property_def_transfer_on_paste (pdef)) continue; } diff --git a/plugins/gtk+/glade-gtk-entry-buffer.c b/plugins/gtk+/glade-gtk-entry-buffer.c index d7001154..bdb5f219 100644 --- a/plugins/gtk+/glade-gtk-entry-buffer.c +++ b/plugins/gtk+/glade-gtk-entry-buffer.c @@ -84,6 +84,6 @@ glade_gtk_entry_buffer_set_property (GladeWidgetAdaptor * adaptor, } else if (GPC_VERSION_CHECK - (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (G_TYPE_OBJECT)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-entry.c b/plugins/gtk+/glade-gtk-entry.c index 94098739..3c2813ee 100644 --- a/plugins/gtk+/glade-gtk-entry.c +++ b/plugins/gtk+/glade-gtk-entry.c @@ -211,7 +211,7 @@ glade_gtk_entry_set_property (GladeWidgetAdaptor *adaptor, GWA_GET_CLASS (GTK_TYPE_WIDGET)->set_property (adaptor, object, id, value); } else if (GPC_VERSION_CHECK - (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_WIDGET)->set_property (adaptor, object, id, value); } @@ -246,7 +246,7 @@ glade_gtk_entry_read_widget (GladeWidgetAdaptor *adaptor, property = glade_widget_get_property (widget, "buffer"); /* Only default to the buffer setting if the project version supports it. */ - if (GPC_VERSION_CHECK (glade_property_get_class (property), target_major, target_minor)) + if (GPC_VERSION_CHECK (glade_property_get_def (property), target_major, target_minor)) { glade_widget_property_set (widget, "use-entry-buffer", TRUE); glade_property_sync (property); diff --git a/plugins/gtk+/glade-gtk-icon-factory.c b/plugins/gtk+/glade-gtk-icon-factory.c index a9c7aaff..6b54f074 100644 --- a/plugins/gtk+/glade-gtk-icon-factory.c +++ b/plugins/gtk+/glade-gtk-icon-factory.c @@ -426,13 +426,13 @@ G_GNUC_END_IGNORE_DEPRECATIONS gchar * glade_gtk_icon_factory_string_from_value (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, const GValue *value) { GString *string; GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_ICON_SOURCES) { @@ -448,27 +448,27 @@ glade_gtk_icon_factory_string_from_value (GladeWidgetAdaptor *adaptor, } else return GWA_GET_CLASS - (G_TYPE_OBJECT)->string_from_value (adaptor, klass, value); + (G_TYPE_OBJECT)->string_from_value (adaptor, def, value); } GladeEditorProperty * glade_gtk_icon_factory_create_eprop (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, gboolean use_command) { GladeEditorProperty *eprop; GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_ICON_SOURCES) eprop = g_object_new (GLADE_TYPE_EPROP_ICON_SOURCES, - "property-class", klass, + "property-def", def, "use-command", use_command, NULL); else eprop = GWA_GET_CLASS - (G_TYPE_OBJECT)->create_eprop (adaptor, klass, use_command); + (G_TYPE_OBJECT)->create_eprop (adaptor, def, use_command); return eprop; } diff --git a/plugins/gtk+/glade-gtk-label.c b/plugins/gtk+/glade-gtk-label.c index 0ec20c39..68dc3100 100644 --- a/plugins/gtk+/glade-gtk-label.c +++ b/plugins/gtk+/glade-gtk-label.c @@ -495,12 +495,12 @@ glade_gtk_label_write_widget (GladeWidgetAdaptor *adaptor, gchar * glade_gtk_label_string_from_value (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, const GValue *value) { GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_ATTR_GLIST) { @@ -523,30 +523,30 @@ glade_gtk_label_string_from_value (GladeWidgetAdaptor *adaptor, } else return GWA_GET_CLASS - (GTK_TYPE_WIDGET)->string_from_value (adaptor, klass, value); + (GTK_TYPE_WIDGET)->string_from_value (adaptor, def, value); } GladeEditorProperty * glade_gtk_label_create_eprop (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, gboolean use_command) { GladeEditorProperty *eprop; GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); /* chain up.. */ if (pspec->value_type == GLADE_TYPE_ATTR_GLIST) { eprop = g_object_new (GLADE_TYPE_EPROP_ATTRS, - "property-class", klass, + "property-def", def, "use-command", use_command, NULL); } else eprop = GWA_GET_CLASS - (GTK_TYPE_WIDGET)->create_eprop (adaptor, klass, use_command); + (GTK_TYPE_WIDGET)->create_eprop (adaptor, def, use_command); return eprop; } diff --git a/plugins/gtk+/glade-gtk-list-store.c b/plugins/gtk+/glade-gtk-list-store.c index 71a0c049..b30b58a1 100644 --- a/plugins/gtk+/glade-gtk-list-store.c +++ b/plugins/gtk+/glade-gtk-list-store.c @@ -143,26 +143,26 @@ glade_gtk_store_set_property (GladeWidgetAdaptor *adaptor, GladeEditorProperty * glade_gtk_store_create_eprop (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, gboolean use_command) { GladeEditorProperty *eprop; GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); /* chain up.. */ if (pspec->value_type == GLADE_TYPE_COLUMN_TYPE_LIST) eprop = g_object_new (GLADE_TYPE_EPROP_COLUMN_TYPES, - "property-class", klass, + "property-def", def, "use-command", use_command, NULL); else if (pspec->value_type == GLADE_TYPE_MODEL_DATA_TREE) eprop = g_object_new (GLADE_TYPE_EPROP_MODEL_DATA, - "property-class", klass, + "property-def", def, "use-command", use_command, NULL); else eprop = GWA_GET_CLASS - (G_TYPE_OBJECT)->create_eprop (adaptor, klass, use_command); + (G_TYPE_OBJECT)->create_eprop (adaptor, def, use_command); return eprop; } @@ -246,13 +246,13 @@ glade_gtk_store_create_editable (GladeWidgetAdaptor *adaptor, gchar * glade_gtk_store_string_from_value (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, const GValue *value) { GString *string; GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_COLUMN_TYPE_LIST) { @@ -320,7 +320,7 @@ glade_gtk_store_string_from_value (GladeWidgetAdaptor *adaptor, } else return GWA_GET_CLASS - (G_TYPE_OBJECT)->string_from_value (adaptor, klass, value); + (G_TYPE_OBJECT)->string_from_value (adaptor, def, value); } static void diff --git a/plugins/gtk+/glade-gtk-menu-item.c b/plugins/gtk+/glade-gtk-menu-item.c index 40dd4ba9..30167ebb 100644 --- a/plugins/gtk+/glade-gtk-menu-item.c +++ b/plugins/gtk+/glade-gtk-menu-item.c @@ -223,7 +223,7 @@ glade_gtk_menu_item_set_property (GladeWidgetAdaptor *adaptor, else if (!strcmp (id, "label")) glade_gtk_menu_item_set_label (object, value); else if (GPC_VERSION_CHECK - (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-progress-bar.c b/plugins/gtk+/glade-gtk-progress-bar.c index 3a8f16eb..4297bbb9 100644 --- a/plugins/gtk+/glade-gtk-progress-bar.c +++ b/plugins/gtk+/glade-gtk-progress-bar.c @@ -64,6 +64,6 @@ glade_gtk_progress_bar_set_property (GladeWidgetAdaptor *adaptor, } } - if (GPC_VERSION_CHECK (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + if (GPC_VERSION_CHECK (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-recent-chooser-menu.c b/plugins/gtk+/glade-gtk-recent-chooser-menu.c index d1aa8961..2bf3be35 100644 --- a/plugins/gtk+/glade-gtk-recent-chooser-menu.c +++ b/plugins/gtk+/glade-gtk-recent-chooser-menu.c @@ -46,6 +46,6 @@ glade_gtk_recent_chooser_menu_set_property (GladeWidgetAdaptor *adaptor, GladeWidget *widget = glade_widget_get_from_gobject (object); GladeProperty *property = glade_widget_get_property (widget, id); - if (GPC_VERSION_CHECK (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + if (GPC_VERSION_CHECK (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_MENU)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-recent-file-filter.c b/plugins/gtk+/glade-gtk-recent-file-filter.c index cc334860..417272c7 100644 --- a/plugins/gtk+/glade-gtk-recent-file-filter.c +++ b/plugins/gtk+/glade-gtk-recent-file-filter.c @@ -133,33 +133,33 @@ glade_gtk_filter_write_strings (GladeWidget *widget, GladeEditorProperty * glade_gtk_recent_file_filter_create_eprop (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, gboolean use_command) { GladeEditorProperty *eprop; GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_STRING_LIST) { - eprop = glade_eprop_string_list_new (klass, use_command, FALSE, FALSE); + eprop = glade_eprop_string_list_new (def, use_command, FALSE, FALSE); } else eprop = GWA_GET_CLASS - (G_TYPE_OBJECT)->create_eprop (adaptor, klass, use_command); + (G_TYPE_OBJECT)->create_eprop (adaptor, def, use_command); return eprop; } gchar * glade_gtk_recent_file_filter_string_from_value (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, const GValue *value) { GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_STRING_LIST) { @@ -169,7 +169,7 @@ glade_gtk_recent_file_filter_string_from_value (GladeWidgetAdaptor *adaptor, } else return GWA_GET_CLASS - (G_TYPE_OBJECT)->string_from_value (adaptor, klass, value); + (G_TYPE_OBJECT)->string_from_value (adaptor, def, value); } void diff --git a/plugins/gtk+/glade-gtk-scale.c b/plugins/gtk+/glade-gtk-scale.c index e134c5b0..23dd7cd8 100644 --- a/plugins/gtk+/glade-gtk-scale.c +++ b/plugins/gtk+/glade-gtk-scale.c @@ -64,6 +64,6 @@ glade_gtk_scale_set_property (GladeWidgetAdaptor *adaptor, } } - if (GPC_VERSION_CHECK (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + if (GPC_VERSION_CHECK (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-scrolled-window.c b/plugins/gtk+/glade-gtk-scrolled-window.c index 3b160e5d..302b12c2 100644 --- a/plugins/gtk+/glade-gtk-scrolled-window.c +++ b/plugins/gtk+/glade-gtk-scrolled-window.c @@ -56,7 +56,7 @@ glade_gtk_scrolled_window_set_property (GladeWidgetAdaptor *adaptor, glade_widget_property_set_sensitive (widget, "window-placement", FALSE, _("This property is disabled")); } - else if (GPC_VERSION_CHECK (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + else if (GPC_VERSION_CHECK (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-text-buffer.c b/plugins/gtk+/glade-gtk-text-buffer.c index bda4e4a8..0886de5f 100644 --- a/plugins/gtk+/glade-gtk-text-buffer.c +++ b/plugins/gtk+/glade-gtk-text-buffer.c @@ -80,6 +80,6 @@ glade_gtk_text_buffer_set_property (GladeWidgetAdaptor * adaptor, } else if (GPC_VERSION_CHECK - (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (G_TYPE_OBJECT)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-tool-item.c b/plugins/gtk+/glade-gtk-tool-item.c index 520ef53d..859613e2 100644 --- a/plugins/gtk+/glade-gtk-tool-item.c +++ b/plugins/gtk+/glade-gtk-tool-item.c @@ -67,7 +67,7 @@ glade_gtk_tool_item_set_property (GladeWidgetAdaptor *adaptor, GladeProperty *property = glade_widget_get_property (gwidget, id); if (GPC_VERSION_CHECK - (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-tree-view.c b/plugins/gtk+/glade-gtk-tree-view.c index 043c75e4..c800d72b 100644 --- a/plugins/gtk+/glade-gtk-tree-view.c +++ b/plugins/gtk+/glade-gtk-tree-view.c @@ -306,6 +306,6 @@ glade_gtk_treeview_set_property (GladeWidgetAdaptor *adaptor, glade_widget_property_set_sensitive (widget, "expander-column", FALSE, _("Expanders are not shown")); } - if (GPC_VERSION_CHECK (glade_property_get_class (property), gtk_major_version, gtk_minor_version + 1)) + if (GPC_VERSION_CHECK (glade_property_get_def (property), gtk_major_version, gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, id, value); } diff --git a/plugins/gtk+/glade-gtk-widget.c b/plugins/gtk+/glade-gtk-widget.c index 3ecf9e6b..84097d17 100644 --- a/plugins/gtk+/glade-gtk-widget.c +++ b/plugins/gtk+/glade-gtk-widget.c @@ -87,7 +87,7 @@ static void glade_gtk_parse_atk_relation (GladeProperty *property, GladeXmlNode *node) { GladeXmlNode *prop; - GladePropertyClass *pclass; + GladePropertyDef *pdef; gchar *type, *target, *id, *tmp; gchar *string = NULL; @@ -110,10 +110,10 @@ glade_gtk_parse_atk_relation (GladeProperty *property, GladeXmlNode *node) continue; } - id = glade_util_read_prop_name (type); - pclass = glade_property_get_class (property); + id = glade_util_read_prop_name (type); + pdef = glade_property_get_def (property); - if (!strcmp (id, glade_property_class_id (pclass))) + if (!strcmp (id, glade_property_def_id (pdef))) { if (string == NULL) string = g_strdup (target); @@ -206,8 +206,8 @@ glade_gtk_parse_atk_props (GladeWidget *widget, GladeXmlNode *node) } /* Set the parsed value on the property ... */ - gvalue = glade_property_class_make_gvalue_from_string - (glade_property_get_class (property), value, glade_widget_get_project (widget)); + gvalue = glade_property_def_make_gvalue_from_string + (glade_property_get_def (property), value, glade_widget_get_project (widget)); glade_property_set_value (property, gvalue); g_value_unset (gvalue); g_free (gvalue); @@ -349,13 +349,13 @@ glade_gtk_widget_write_atk_property (GladeProperty *property, if (value && value[0]) { - GladePropertyClass *pclass = glade_property_get_class (property); + GladePropertyDef *pdef = glade_property_get_def (property); GladeXmlNode *prop_node = glade_xml_node_new (context, GLADE_TAG_A11Y_PROPERTY); glade_xml_node_append_child (node, prop_node); glade_xml_node_set_property_string (prop_node, - GLADE_TAG_NAME, glade_property_class_id (pclass)); + GLADE_TAG_NAME, glade_property_def_id (pdef)); glade_xml_set_content (prop_node, value); @@ -437,26 +437,26 @@ glade_gtk_widget_write_atk_relation (GladeProperty *property, GladeXmlNode *node) { GladeXmlNode *prop_node; - GladePropertyClass *pclass; + GladePropertyDef *pdef; gchar *value, **split; gint i; if ((value = glade_widget_adaptor_string_from_value - (glade_property_class_get_adaptor (glade_property_get_class (property)), - glade_property_get_class (property), glade_property_inline_value (property))) != NULL) + (glade_property_def_get_adaptor (glade_property_get_def (property)), + glade_property_get_def (property), glade_property_inline_value (property))) != NULL) { if ((split = g_strsplit (value, GPC_OBJECT_DELIMITER, 0)) != NULL) { for (i = 0; split[i] != NULL; i++) { - pclass = glade_property_get_class (property); + pdef = glade_property_get_def (property); prop_node = glade_xml_node_new (context, GLADE_TAG_A11Y_RELATION); glade_xml_node_append_child (node, prop_node); glade_xml_node_set_property_string (prop_node, GLADE_TAG_A11Y_TYPE, - glade_property_class_id (pclass)); + glade_property_def_id (pdef)); glade_xml_node_set_property_string (prop_node, GLADE_TAG_A11Y_TARGET, split[i]); @@ -494,13 +494,13 @@ glade_gtk_widget_write_atk_action (GladeProperty *property, if (value && value[0]) { - GladePropertyClass *pclass = glade_property_get_class (property); + GladePropertyDef *pdef = glade_property_get_def (property); GladeXmlNode *prop_node = glade_xml_node_new (context, GLADE_TAG_A11Y_ACTION); glade_xml_node_append_child (node, prop_node); glade_xml_node_set_property_string (prop_node, GLADE_TAG_A11Y_ACTION_NAME, - &glade_property_class_id (pclass)[4]); + &glade_property_def_id (pdef)[4]); glade_xml_node_set_property_string (prop_node, GLADE_TAG_A11Y_DESC, value); } @@ -623,24 +623,24 @@ glade_gtk_widget_write_widget_after (GladeWidgetAdaptor *adaptor, GladeEditorProperty * glade_gtk_widget_create_eprop (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, gboolean use_command) { GladeEditorProperty *eprop; GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); /* chain up.. */ if (pspec->value_type == GLADE_TYPE_ACCEL_GLIST) eprop = g_object_new (GLADE_TYPE_EPROP_ACCEL, - "property-class", klass, + "property-def", def, "use-command", use_command, NULL); else if (pspec->value_type == GLADE_TYPE_STRING_LIST) - eprop = glade_eprop_string_list_new (klass, use_command, FALSE, FALSE); + eprop = glade_eprop_string_list_new (def, use_command, FALSE, FALSE); else eprop = GWA_GET_CLASS - (G_TYPE_OBJECT)->create_eprop (adaptor, klass, use_command); + (G_TYPE_OBJECT)->create_eprop (adaptor, def, use_command); return eprop; } @@ -662,12 +662,12 @@ glade_gtk_widget_create_editable (GladeWidgetAdaptor *adaptor, gchar * glade_gtk_widget_string_from_value (GladeWidgetAdaptor *adaptor, - GladePropertyClass *klass, + GladePropertyDef *def, const GValue *value) { GParamSpec *pspec; - pspec = glade_property_class_get_pspec (klass); + pspec = glade_property_def_get_pspec (def); if (pspec->value_type == GLADE_TYPE_ACCEL_GLIST) return glade_accels_make_string (g_value_get_boxed (value)); @@ -679,7 +679,7 @@ glade_gtk_widget_string_from_value (GladeWidgetAdaptor *adaptor, } else return GWA_GET_CLASS - (G_TYPE_OBJECT)->string_from_value (adaptor, klass, value); + (G_TYPE_OBJECT)->string_from_value (adaptor, def, value); } static void @@ -797,9 +797,9 @@ create_command_property_list (GladeWidget *gnew, GList *saved_props) for (l = saved_props; l; l = l->next) { GladeProperty *property = l->data; - GladePropertyClass *pclass = glade_property_get_class (property); + GladePropertyDef *pdef = glade_property_get_def (property); GladeProperty *orig_prop = - glade_widget_get_pack_property (gnew, glade_property_class_id (pclass)); + glade_widget_get_pack_property (gnew, glade_property_def_id (pdef)); GCSetPropData *pdata = g_new0 (GCSetPropData, 1); pdata->property = orig_prop; diff --git a/plugins/gtk+/glade-string-list.c b/plugins/gtk+/glade-string-list.c index 454e23de..d45240c6 100644 --- a/plugins/gtk+/glade-string-list.c +++ b/plugins/gtk+/glade-string-list.c @@ -757,14 +757,14 @@ glade_eprop_string_list_create_input (GladeEditorProperty *eprop) } GladeEditorProperty * -glade_eprop_string_list_new (GladePropertyClass *pclass, +glade_eprop_string_list_new (GladePropertyDef *pdef, gboolean use_command, gboolean translatable, gboolean with_id) { GladeEditorProperty *eprop = g_object_new (GLADE_TYPE_EPROP_STRING_LIST, - "property-class", pclass, + "property-def", pdef, "use-command", use_command, NULL); diff --git a/plugins/gtk+/glade-string-list.h b/plugins/gtk+/glade-string-list.h index 355bc451..bfbfe02f 100644 --- a/plugins/gtk+/glade-string-list.h +++ b/plugins/gtk+/glade-string-list.h @@ -36,10 +36,10 @@ GList *glade_string_list_append (GList *list, gchar *glade_string_list_to_string (GList *list); -GladeEditorProperty *glade_eprop_string_list_new (GladePropertyClass *pclass, - gboolean use_command, - gboolean translatable, - gboolean with_id); +GladeEditorProperty *glade_eprop_string_list_new (GladePropertyDef *pdef, + gboolean use_command, + gboolean translatable, + gboolean with_id); G_END_DECLS |