forked from AuroraMiddleware/gtk
GtkDialog: Warn about lack of transient parents
We want make it mandatory for dialogs to have transient parents, eventually. This is a first step in that direction.
This commit is contained in:
parent
3db60baf2d
commit
c4ec89cf9d
@ -793,6 +793,9 @@ gtk_dialog_map (GtkWidget *widget)
|
||||
GtkWindow *window = GTK_WINDOW (widget);
|
||||
GtkDialog *dialog = GTK_DIALOG (widget);
|
||||
|
||||
if (gtk_window_get_transient_for (window) == NULL)
|
||||
g_warning ("GtkDialog mapped without a transient parent. This is discouraged.");
|
||||
|
||||
GTK_WIDGET_CLASS (gtk_dialog_parent_class)->map (widget);
|
||||
|
||||
focus = gtk_window_get_focus (window);
|
||||
|
Loading…
Reference in New Issue
Block a user