Clean up debug features

Introduce a GTK_DEBUG_CHECK() macro and use it to check for
GTK_DEBUG flags everywhere. Also guard all such places by
This commit is contained in:
Matthias Clasen
2015-09-08 22:48:44 -04:00
parent 1b15588732
commit 3526b08e01
13 changed files with 107 additions and 72 deletions

View File

@ -752,7 +752,7 @@ _gtk_builder_construct (GtkBuilder *builder,
g_object_set_property (obj, param->name, &param->value);
#if G_ENABLE_DEBUG
if (gtk_get_debug_flags () & GTK_DEBUG_BUILDER)
if (GTK_DEBUG_CHECK (BUILDER))
{
gchar *str = g_strdup_value_contents ((const GValue*)&param->value);
g_print ("set %s: %s = %s\n", info->id, param->name, str);
@ -816,7 +816,7 @@ _gtk_builder_apply_properties (GtkBuilder *builder,
g_object_set_property (info->object, param->name, &param->value);
#if G_ENABLE_DEBUG
if (gtk_get_debug_flags () & GTK_DEBUG_BUILDER)
if (GTK_DEBUG_CHECK (BUILDER))
{
gchar *str = g_strdup_value_contents ((const GValue*)&param->value);
g_print ("set %s: %s = %s\n", info->id, param->name, str);