builder-tool: Don't try to find default boxed values
authorMatthias Clasen <mclasen@redhat.com>
Fri, 13 Dec 2019 18:11:59 +0000 (13:11 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Fri, 13 Dec 2019 19:21:44 +0000 (14:21 -0500)
This doesn't work and yields an ugly, unnecessary
error message.

gtk/tools/gtk-builder-tool-simplify.c

index 3cd917f2cd4f90d5a4854b0e7a9ea6c3f6cfa499..06689ce9c5105e53e940bcc5120cf644b1ec4d6f 100644 (file)
@@ -449,6 +449,9 @@ value_is_default (Element      *element,
   if (g_type_is_a (G_PARAM_SPEC_VALUE_TYPE (pspec), G_TYPE_OBJECT))
     return FALSE;
 
+  if (g_type_is_a (G_PARAM_SPEC_VALUE_TYPE (pspec), G_TYPE_BOXED))
+    return FALSE;
+
   if (!gtk_builder_value_from_string (data->builder, pspec, value_string, &value, &error))
     {
       g_printerr (_("%s:%d: Couldn’t parse value for property '%s': %s\n"), data->input_filename, element->line_number, pspec->name, error->message);