Make GTK_DEBUG=interactive work better
We currently have various ways to initialize GTK+, and not all of them were supporting this way of bringing up the inspector. Fix this. https://bugzilla.gnome.org/show_bug.cgi?id=776807
This commit is contained in:
@ -809,6 +809,9 @@ post_parse_hook (GOptionContext *context,
|
|||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (gtk_get_debug_flags () & GTK_DEBUG_INTERACTIVE)
|
||||||
|
gtk_window_set_interactive_debugging (TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -988,7 +991,15 @@ gtk_init_with_args (gint *argc,
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
done:
|
done:
|
||||||
return GDK_PRIVATE_CALL (gdk_display_open_default) () != NULL;
|
if (GDK_PRIVATE_CALL (gdk_display_open_default) () != NULL)
|
||||||
|
{
|
||||||
|
if (gtk_get_debug_flags () & GTK_DEBUG_INTERACTIVE)
|
||||||
|
gtk_window_set_interactive_debugging (TRUE);
|
||||||
|
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user