diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2014-08-12 11:54:08 +0100 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2014-08-12 11:54:08 +0100 |
commit | 54edcca4d5bf9f739b54bcc0ed403cfd010d00c9 (patch) | |
tree | bb1735552d0a5b59990ec7bf7d27ec26546523b5 | |
parent | ca380707e3999732374a7e617b2004b2a1a1c9dd (diff) | |
download | gtk+-54edcca4d5bf9f739b54bcc0ed403cfd010d00c9.tar.gz |
glarea: Unconditionally call gdk_gl_context_update()
There's no need to check for different sizes.
-rw-r--r-- | gtk/gtkglarea.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/gtk/gtkglarea.c b/gtk/gtkglarea.c index d020d28d1d..a2800bfa7e 100644 --- a/gtk/gtkglarea.c +++ b/gtk/gtkglarea.c @@ -189,26 +189,19 @@ gtk_gl_area_size_allocate (GtkWidget *widget, GtkAllocation *allocation) { GtkGLAreaPrivate *priv = gtk_gl_area_get_instance_private ((GtkGLArea *) widget); - GtkAllocation old_alloc; - gboolean same_size; - gtk_widget_get_allocation (widget, &old_alloc); gtk_widget_set_allocation (widget, allocation); if (!gtk_widget_get_realized (widget)) return; - same_size = old_alloc.width == allocation->width && - old_alloc.height == allocation->height; - gdk_window_move_resize (gtk_widget_get_window (widget), allocation->x, allocation->y, allocation->width, allocation->height); - /* no need to reset the viewport if the size of the window did not change */ - if (priv->context != NULL && !same_size) + if (priv->context != NULL) gdk_gl_context_update (priv->context); } |