From d4e8ab0234b32df463b95f517077f4331a46dd9f Mon Sep 17 00:00:00 2001 From: Michael Natterer Date: Thu, 17 Jul 2025 09:28:26 +0200 Subject: [PATCH] app: rename GimpContainer's "children-type" property to "child-type" --- app/core/gimp.c | 14 +++++++------- app/core/gimpcontainer-filter.c | 4 ++-- app/core/gimpcontainer.c | 10 +++++----- app/core/gimpdocumentlist.c | 6 +++--- app/core/gimpdrawablestack.c | 6 +++--- app/core/gimpfilteredcontainer.c | 2 +- app/core/gimpfilterstack.c | 6 +++--- app/core/gimpitemstack.c | 6 +++--- app/core/gimpitemtree.c | 6 +++--- app/core/gimplayerstack.c | 6 +++--- app/core/gimplist.c | 12 ++++++------ app/core/gimptaggedcontainer.c | 2 +- app/core/gimptoolgroup.c | 9 ++++----- app/core/gimptreeproxy.c | 6 +++--- app/display/gimptoolwidgetgroup.c | 4 ++-- app/tools/gimp-tools.c | 4 ++-- app/widgets/gimpcontrollermanager.c | 2 +- app/widgets/gimpdevicemanager.c | 10 +++++----- 18 files changed, 57 insertions(+), 58 deletions(-) diff --git a/app/core/gimp.c b/app/core/gimp.c index d7f4dea35f..78a5d69e13 100644 --- a/app/core/gimp.c +++ b/app/core/gimp.c @@ -254,9 +254,9 @@ gimp_init (Gimp *gimp) gimp->drawable_filter_table = gimp_id_table_new (); gimp->displays = g_object_new (GIMP_TYPE_LIST, - "children-type", GIMP_TYPE_OBJECT, - "policy", GIMP_CONTAINER_POLICY_WEAK, - "append", TRUE, + "child-type", GIMP_TYPE_OBJECT, + "policy", GIMP_CONTAINER_POLICY_WEAK, + "append", TRUE, NULL); gimp_object_set_static_name (GIMP_OBJECT (gimp->displays), "displays"); gimp->next_display_id = 1; @@ -268,15 +268,15 @@ gimp_init (Gimp *gimp) gimp_data_factories_init (gimp); gimp->tool_info_list = g_object_new (GIMP_TYPE_LIST, - "children-type", GIMP_TYPE_TOOL_INFO, - "append", TRUE, + "child-type", GIMP_TYPE_TOOL_INFO, + "append", TRUE, NULL); gimp_object_set_static_name (GIMP_OBJECT (gimp->tool_info_list), "tool infos"); gimp->tool_item_list = g_object_new (GIMP_TYPE_LIST, - "children-type", GIMP_TYPE_TOOL_ITEM, - "append", TRUE, + "child-type", GIMP_TYPE_TOOL_ITEM, + "append", TRUE, NULL); gimp_object_set_static_name (GIMP_OBJECT (gimp->tool_item_list), "tool items"); diff --git a/app/core/gimpcontainer-filter.c b/app/core/gimpcontainer-filter.c index 4a7b99fec6..5ffc6010ae 100644 --- a/app/core/gimpcontainer-filter.c +++ b/app/core/gimpcontainer-filter.c @@ -71,8 +71,8 @@ gimp_container_filter (GimpContainer *container, result = g_object_new (G_TYPE_FROM_INSTANCE (container), - "children-type", gimp_container_get_children_type (container), - "policy", GIMP_CONTAINER_POLICY_WEAK, + "child-type", gimp_container_get_children_type (container), + "policy", GIMP_CONTAINER_POLICY_WEAK, NULL); context.filter = filter; diff --git a/app/core/gimpcontainer.c b/app/core/gimpcontainer.c index b36e964127..f1723f600e 100644 --- a/app/core/gimpcontainer.c +++ b/app/core/gimpcontainer.c @@ -56,7 +56,7 @@ enum enum { PROP_0, - PROP_CHILDREN_TYPE, + PROP_CHILD_TYPE, PROP_POLICY }; @@ -212,8 +212,8 @@ gimp_container_class_init (GimpContainerClass *klass) klass->get_child_by_index = NULL; klass->get_child_index = NULL; - g_object_class_install_property (object_class, PROP_CHILDREN_TYPE, - g_param_spec_gtype ("children-type", + g_object_class_install_property (object_class, PROP_CHILD_TYPE, + g_param_spec_gtype ("child-type", NULL, NULL, GIMP_TYPE_OBJECT, GIMP_PARAM_READWRITE | @@ -287,7 +287,7 @@ gimp_container_set_property (GObject *object, switch (property_id) { - case PROP_CHILDREN_TYPE: + case PROP_CHILD_TYPE: container->priv->child_type = g_value_get_gtype (value); g_type_class_ref (container->priv->child_type); break; @@ -310,7 +310,7 @@ gimp_container_get_property (GObject *object, switch (property_id) { - case PROP_CHILDREN_TYPE: + case PROP_CHILD_TYPE: g_value_set_gtype (value, container->priv->child_type); break; case PROP_POLICY: diff --git a/app/core/gimpdocumentlist.c b/app/core/gimpdocumentlist.c index fe10f6fcac..fd9b8a1212 100644 --- a/app/core/gimpdocumentlist.c +++ b/app/core/gimpdocumentlist.c @@ -52,9 +52,9 @@ gimp_document_list_new (Gimp *gimp) g_return_val_if_fail (GIMP_IS_GIMP (gimp), NULL); document_list = g_object_new (GIMP_TYPE_DOCUMENT_LIST, - "name", "document-list", - "children-type", GIMP_TYPE_IMAGEFILE, - "policy", GIMP_CONTAINER_POLICY_STRONG, + "name", "document-list", + "child-type", GIMP_TYPE_IMAGEFILE, + "policy", GIMP_CONTAINER_POLICY_STRONG, NULL); document_list->gimp = gimp; diff --git a/app/core/gimpdrawablestack.c b/app/core/gimpdrawablestack.c index c8e706a594..bd348d1aab 100644 --- a/app/core/gimpdrawablestack.c +++ b/app/core/gimpdrawablestack.c @@ -161,9 +161,9 @@ gimp_drawable_stack_new (GType drawable_type) g_return_val_if_fail (g_type_is_a (drawable_type, GIMP_TYPE_DRAWABLE), NULL); return g_object_new (GIMP_TYPE_DRAWABLE_STACK, - "name", g_type_name (drawable_type), - "children-type", drawable_type, - "policy", GIMP_CONTAINER_POLICY_STRONG, + "name", g_type_name (drawable_type), + "child-type", drawable_type, + "policy", GIMP_CONTAINER_POLICY_STRONG, NULL); } diff --git a/app/core/gimpfilteredcontainer.c b/app/core/gimpfilteredcontainer.c index 6e2b8275b7..b1e09dac01 100644 --- a/app/core/gimpfilteredcontainer.c +++ b/app/core/gimpfilteredcontainer.c @@ -314,7 +314,7 @@ gimp_filtered_container_new (GimpContainer *src_container, return g_object_new (GIMP_TYPE_FILTERED_CONTAINER, "sort-func", sort_func, - "children-type", child_type, + "child-type", child_type, "policy", GIMP_CONTAINER_POLICY_WEAK, "unique-names", FALSE, "src-container", src_container, diff --git a/app/core/gimpfilterstack.c b/app/core/gimpfilterstack.c index d470918ea0..8d16bcfaf6 100644 --- a/app/core/gimpfilterstack.c +++ b/app/core/gimpfilterstack.c @@ -175,9 +175,9 @@ gimp_filter_stack_new (GType filter_type) g_return_val_if_fail (g_type_is_a (filter_type, GIMP_TYPE_FILTER), NULL); return g_object_new (GIMP_TYPE_FILTER_STACK, - "name", g_type_name (filter_type), - "children-type", filter_type, - "policy", GIMP_CONTAINER_POLICY_STRONG, + "name", g_type_name (filter_type), + "child-type", filter_type, + "policy", GIMP_CONTAINER_POLICY_STRONG, NULL); } diff --git a/app/core/gimpitemstack.c b/app/core/gimpitemstack.c index c7f2fe1b82..4ae06a8ca6 100644 --- a/app/core/gimpitemstack.c +++ b/app/core/gimpitemstack.c @@ -104,9 +104,9 @@ gimp_item_stack_new (GType item_type) g_return_val_if_fail (g_type_is_a (item_type, GIMP_TYPE_ITEM), NULL); return g_object_new (GIMP_TYPE_ITEM_STACK, - "name", g_type_name (item_type), - "children-type", item_type, - "policy", GIMP_CONTAINER_POLICY_STRONG, + "name", g_type_name (item_type), + "child-type", item_type, + "policy", GIMP_CONTAINER_POLICY_STRONG, NULL); } diff --git a/app/core/gimpitemtree.c b/app/core/gimpitemtree.c index 4e6c7746f9..475dac3e4d 100644 --- a/app/core/gimpitemtree.c +++ b/app/core/gimpitemtree.c @@ -163,9 +163,9 @@ gimp_item_tree_constructed (GObject *object) gimp_assert (private->item_type != GIMP_TYPE_ITEM); tree->container = g_object_new (private->container_type, - "name", g_type_name (private->item_type), - "children-type", private->item_type, - "policy", GIMP_CONTAINER_POLICY_STRONG, + "name", g_type_name (private->item_type), + "child-type", private->item_type, + "policy", GIMP_CONTAINER_POLICY_STRONG, NULL); } diff --git a/app/core/gimplayerstack.c b/app/core/gimplayerstack.c index 1540189252..f3d881d5aa 100644 --- a/app/core/gimplayerstack.c +++ b/app/core/gimplayerstack.c @@ -157,9 +157,9 @@ gimp_layer_stack_new (GType layer_type) g_return_val_if_fail (g_type_is_a (layer_type, GIMP_TYPE_LAYER), NULL); return g_object_new (GIMP_TYPE_LAYER_STACK, - "name", g_type_name (layer_type), - "children-type", layer_type, - "policy", GIMP_CONTAINER_POLICY_STRONG, + "name", g_type_name (layer_type), + "child-type", layer_type, + "policy", GIMP_CONTAINER_POLICY_STRONG, NULL); } diff --git a/app/core/gimplist.c b/app/core/gimplist.c index bcfea47a07..5603d61db5 100644 --- a/app/core/gimplist.c +++ b/app/core/gimplist.c @@ -450,9 +450,9 @@ gimp_list_new (GType child_type, g_return_val_if_fail (g_type_is_a (child_type, GIMP_TYPE_OBJECT), NULL); list = g_object_new (GIMP_TYPE_LIST, - "children-type", child_type, - "policy", GIMP_CONTAINER_POLICY_STRONG, - "unique-names", unique_names ? TRUE : FALSE, + "child-type", child_type, + "policy", GIMP_CONTAINER_POLICY_STRONG, + "unique-names", unique_names ? TRUE : FALSE, NULL); /* for debugging purposes only */ @@ -484,9 +484,9 @@ gimp_list_new_weak (GType child_type, g_return_val_if_fail (g_type_is_a (child_type, GIMP_TYPE_OBJECT), NULL); list = g_object_new (GIMP_TYPE_LIST, - "children-type", child_type, - "policy", GIMP_CONTAINER_POLICY_WEAK, - "unique-names", unique_names ? TRUE : FALSE, + "child-type", child_type, + "policy", GIMP_CONTAINER_POLICY_WEAK, + "unique-names", unique_names ? TRUE : FALSE, NULL); /* for debugging purposes only */ diff --git a/app/core/gimptaggedcontainer.c b/app/core/gimptaggedcontainer.c index f73bd9f0ee..17927094f5 100644 --- a/app/core/gimptaggedcontainer.c +++ b/app/core/gimptaggedcontainer.c @@ -271,7 +271,7 @@ gimp_tagged_container_new (GimpContainer *src_container) tagged_container = g_object_new (GIMP_TYPE_TAGGED_CONTAINER, "sort-func", sort_func, - "children-type", child_type, + "child-type", child_type, "policy", GIMP_CONTAINER_POLICY_WEAK, "unique-names", FALSE, "src-container", src_container, diff --git a/app/core/gimptoolgroup.c b/app/core/gimptoolgroup.c index 20bd52bbcb..33cddc8bc0 100644 --- a/app/core/gimptoolgroup.c +++ b/app/core/gimptoolgroup.c @@ -147,11 +147,10 @@ gimp_tool_group_init (GimpToolGroup *tool_group) { tool_group->priv = gimp_tool_group_get_instance_private (tool_group); - tool_group->priv->children = g_object_new ( - GIMP_TYPE_LIST, - "children-type", GIMP_TYPE_TOOL_INFO, - "append", TRUE, - NULL); + tool_group->priv->children = g_object_new (GIMP_TYPE_LIST, + "child-type", GIMP_TYPE_TOOL_INFO, + "append", TRUE, + NULL); g_signal_connect (tool_group->priv->children, "add", G_CALLBACK (gimp_tool_group_child_add), diff --git a/app/core/gimptreeproxy.c b/app/core/gimptreeproxy.c index 544d411ba2..61bc6f3a23 100644 --- a/app/core/gimptreeproxy.c +++ b/app/core/gimptreeproxy.c @@ -518,9 +518,9 @@ gimp_tree_proxy_new (GType child_type) g_type_class_unref (children_class); return g_object_new (GIMP_TYPE_TREE_PROXY, - "children-type", child_type, - "policy", GIMP_CONTAINER_POLICY_WEAK, - "append", TRUE, + "child-type", child_type, + "policy", GIMP_CONTAINER_POLICY_WEAK, + "append", TRUE, NULL); } diff --git a/app/display/gimptoolwidgetgroup.c b/app/display/gimptoolwidgetgroup.c index d62f4c926b..096a344ca3 100644 --- a/app/display/gimptoolwidgetgroup.c +++ b/app/display/gimptoolwidgetgroup.c @@ -175,8 +175,8 @@ gimp_tool_widget_group_init (GimpToolWidgetGroup *group) priv = group->priv = gimp_tool_widget_group_get_instance_private (group); priv->children = g_object_new (GIMP_TYPE_LIST, - "children-type", GIMP_TYPE_TOOL_WIDGET, - "append", TRUE, + "child-type", GIMP_TYPE_TOOL_WIDGET, + "append", TRUE, NULL); g_signal_connect (priv->children, "add", diff --git a/app/tools/gimp-tools.c b/app/tools/gimp-tools.c index 110bfe0201..7179c09358 100644 --- a/app/tools/gimp-tools.c +++ b/app/tools/gimp-tools.c @@ -521,8 +521,8 @@ gimp_tools_deserialize (Gimp *gimp, gimp_container_clear (container); src_container = g_object_new (GIMP_TYPE_LIST, - "children-type", GIMP_TYPE_TOOL_ITEM, - "append", TRUE, + "child-type", GIMP_TYPE_TOOL_ITEM, + "append", TRUE, NULL); if (gimp_config_deserialize (GIMP_CONFIG (src_container), diff --git a/app/widgets/gimpcontrollermanager.c b/app/widgets/gimpcontrollermanager.c index 6a795a21a2..a7c5a7d400 100644 --- a/app/widgets/gimpcontrollermanager.c +++ b/app/widgets/gimpcontrollermanager.c @@ -152,7 +152,7 @@ gimp_controller_manager_new (Gimp *gimp) g_return_val_if_fail (GIMP_IS_GIMP (gimp), NULL); self = g_object_new (GIMP_TYPE_CONTROLLER_MANAGER, - "children-type", GIMP_TYPE_CONTROLLER_INFO, + "child-type", GIMP_TYPE_CONTROLLER_INFO, NULL); self->gimp = gimp; diff --git a/app/widgets/gimpdevicemanager.c b/app/widgets/gimpdevicemanager.c index 8c54f61a5f..1d24ee245f 100644 --- a/app/widgets/gimpdevicemanager.c +++ b/app/widgets/gimpdevicemanager.c @@ -295,11 +295,11 @@ gimp_device_manager_new (Gimp *gimp) g_return_val_if_fail (GIMP_IS_GIMP (gimp), NULL); return g_object_new (GIMP_TYPE_DEVICE_MANAGER, - "gimp", gimp, - "children-type", GIMP_TYPE_DEVICE_INFO, - "policy", GIMP_CONTAINER_POLICY_STRONG, - "unique-names", TRUE, - "sort-func", gimp_device_info_compare, + "gimp", gimp, + "child-type", GIMP_TYPE_DEVICE_INFO, + "policy", GIMP_CONTAINER_POLICY_STRONG, + "unique-names", TRUE, + "sort-func", gimp_device_info_compare, NULL); }