forked from AuroraMiddleware/gtk
glarea: Always delete textures on unrealize
We need to make the context current for deleting textures as well, so just do it unconditionally.
This commit is contained in:
parent
6ea827cde5
commit
0429008b16
@ -623,13 +623,9 @@ gtk_gl_area_unrealize (GtkWidget *widget)
|
||||
|
||||
if (priv->context != NULL)
|
||||
{
|
||||
if (priv->have_buffers)
|
||||
{
|
||||
gtk_gl_area_make_current (area);
|
||||
gtk_gl_area_delete_buffers (area);
|
||||
}
|
||||
|
||||
gtk_gl_area_delete_textures (area);
|
||||
gtk_gl_area_make_current (area);
|
||||
gtk_gl_area_delete_buffers (area);
|
||||
gtk_gl_area_delete_textures (area);
|
||||
|
||||
/* Make sure to unset the context if current */
|
||||
if (priv->context == gdk_gl_context_get_current ())
|
||||
|
Loading…
Reference in New Issue
Block a user