aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/callbacks.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/callbacks.c b/src/callbacks.c
index 60d6971..0719573 100644
--- a/src/callbacks.c
+++ b/src/callbacks.c
@@ -660,9 +660,10 @@ static void show_buffer(cam* cam)
NULL);
GtkWidget *widget = GTK_WIDGET(gtk_builder_get_object(cam->xml, "da"));
+ GdkWindow *window = gtk_widget_get_window(widget);
- cairo_surface_t *surface = create_from_pixbuf(pb, widget->window);
- cairo_t *cr = gdk_cairo_create(widget->window);
+ cairo_surface_t *surface = create_from_pixbuf(pb, window);
+ cairo_t *cr = gdk_cairo_create(window);
cairo_set_source_surface(cr, surface, 0, 0);
gdk_cairo_rectangle(cr, &rect);

Privacy Policy