Commit 1cfeeadc authored by Carlos Garnacho's avatar Carlos Garnacho

GtkWidget: Ensure the style context always has an screen.

Things like font settings depend on the screen, and widgets
like GtkTextView trigger queries on widgets without screen
when the parent window is being destroyed.
parent 48f239c1
......@@ -8388,7 +8388,7 @@ do_screen_change (GtkWidget *widget,
_gtk_tooltip_hide (widget);
context = gtk_widget_get_style_context (widget);
gtk_style_context_set_screen (context, new_screen);
gtk_style_context_set_screen (context, gtk_widget_get_screen (widget));
g_signal_emit (widget, widget_signals[SCREEN_CHANGED], 0, old_screen);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment