[gtk+/wip/gdk-gl] glarea: Ensure that the viewport is correctly set
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/gdk-gl] glarea: Ensure that the viewport is correctly set
- Date: Mon, 18 Aug 2014 17:09:39 +0000 (UTC)
commit 6d22f2a46a20623d51b6713dcc452d526d27360e
Author: Emmanuele Bassi <ebassi gnome org>
Date: Mon Aug 18 18:07:45 2014 +0100
glarea: Ensure that the viewport is correctly set
Call gdk_gl_context_update() once we create the GdkWindow inside the
::realize implementation of GtkGLArea, to ensure that the GL viewport is
updated with the size of the GDK window.
gtk/gtkglarea.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkglarea.c b/gtk/gtkglarea.c
index 00f0cf5..eba440a 100644
--- a/gtk/gtkglarea.c
+++ b/gtk/gtkglarea.c
@@ -296,7 +296,10 @@ gtk_gl_area_realize (GtkWidget *widget)
gtk_widget_set_window (widget, window);
if (context != NULL)
- gdk_gl_context_set_window (context, gtk_widget_get_window (widget));
+ {
+ gdk_gl_context_set_window (context, window);
+ gdk_gl_context_update (context);
+ }
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]