summaryrefslogtreecommitdiff
path: root/gtk/gtkiconhelper.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2017-01-10 18:37:12 -0500
committerMatthias Clasen <mclasen@redhat.com>2017-01-10 19:56:02 -0500
commita013a16d1ceab34927a81f7f380823cf6bb4b72a (patch)
tree55ac943062d39abd2e52794a01c9b1fee1737eef /gtk/gtkiconhelper.c
parentd9bc675cbab744733fb805163a0e95fc7cdf3280 (diff)
downloadgtk+-a013a16d1ceab34927a81f7f380823cf6bb4b72a.tar.gz
Use _gtk_widget_get_window more
This avoids type checks in places where we know it is safe.
Diffstat (limited to 'gtk/gtkiconhelper.c')
-rw-r--r--gtk/gtkiconhelper.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gtk/gtkiconhelper.c b/gtk/gtkiconhelper.c
index 72eaa62f72..15d6e42ccc 100644
--- a/gtk/gtkiconhelper.c
+++ b/gtk/gtkiconhelper.c
@@ -32,6 +32,7 @@
#include "gtkiconthemeprivate.h"
#include "gtkrendericonprivate.h"
#include "gtksnapshot.h"
+#include "gtkwidgetprivate.h"
struct _GtkIconHelperPrivate {
GtkImageDefinition *def;
@@ -391,7 +392,7 @@ ensure_surface_from_pixbuf (GtkIconHelper *self,
else
pixbuf = g_object_ref (orig_pixbuf);
- surface = gdk_cairo_surface_create_from_pixbuf (pixbuf, scale, gtk_widget_get_window (gtk_css_gadget_get_owner (GTK_CSS_GADGET (self))));
+ surface = gdk_cairo_surface_create_from_pixbuf (pixbuf, scale, _gtk_widget_get_window (gtk_css_gadget_get_owner (GTK_CSS_GADGET (self))));
g_object_unref (pixbuf);
return surface;
@@ -464,7 +465,7 @@ ensure_surface_for_gicon (GtkIconHelper *self,
symbolic = FALSE;
}
- surface = gdk_cairo_surface_create_from_pixbuf (destination, scale, gtk_widget_get_window (gtk_css_gadget_get_owner (GTK_CSS_GADGET (self))));
+ surface = gdk_cairo_surface_create_from_pixbuf (destination, scale, _gtk_widget_get_window (gtk_css_gadget_get_owner (GTK_CSS_GADGET (self))));
if (symbolic)
{