[gtk/misc-texture-things: 3/3] pixbufutils: Simplify function
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/misc-texture-things: 3/3] pixbufutils: Simplify function
- Date: Thu, 16 Sep 2021 02:01:14 +0000 (UTC)
commit 7fd889909277b9b8e7fc6c8e9f592f7515ed4463
Author: Benjamin Otte <otte redhat com>
Date: Tue Sep 14 18:17:44 2021 +0200
pixbufutils: Simplify function
gtk/gdkpixbufutils.c | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)
---
diff --git a/gtk/gdkpixbufutils.c b/gtk/gdkpixbufutils.c
index d1b6693918..2b48d76943 100644
--- a/gtk/gdkpixbufutils.c
+++ b/gtk/gdkpixbufutils.c
@@ -505,14 +505,7 @@ gtk_make_symbolic_pixbuf_from_file (GFile *file,
GdkTexture *
gtk_load_symbolic_texture_from_resource (const char *path)
{
- GdkPixbuf *pixbuf;
- GdkTexture *texture;
-
- pixbuf = _gdk_pixbuf_new_from_resource (path, "png", NULL);
- texture = gdk_texture_new_for_pixbuf (pixbuf);
- g_object_unref (pixbuf);
-
- return texture;
+ return gdk_texture_new_from_resource (path);
}
GdkTexture *
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]