window: Make unrealize work again

GtkWidgets unrealize accesses the frame clock
of the surface, so we need to keep the surface
in place until after we've chained up.
This commit is contained in:
Matthias Clasen 2019-05-18 13:39:12 +00:00
parent b99962e7a2
commit 0b3a971056

View File

@ -5836,12 +5836,13 @@ gtk_window_unrealize (GtkWidget *widget)
g_signal_handlers_disconnect_by_func (surface, surface_size_changed, widget);
g_signal_handlers_disconnect_by_func (surface, surface_render, widget);
g_signal_handlers_disconnect_by_func (surface, surface_event, widget);
GTK_WIDGET_CLASS (gtk_window_parent_class)->unrealize (widget);
gdk_surface_set_widget (surface, NULL);
gdk_surface_destroy (surface);
g_clear_object (&priv->surface);
GTK_WIDGET_CLASS (gtk_window_parent_class)->unrealize (widget);
priv->hardcoded_surface = NULL;
}