From 667503ef7dc41b9cdfc4a6bd0d47c306f0dbb8e0 Mon Sep 17 00:00:00 2001 From: Jonas Berlin Date: Wed, 4 Dec 2019 20:59:19 +0200 Subject: [PATCH] Cleanup, documentation --- src/icon.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/icon.c b/src/icon.c index d07e8ea..6359933 100644 --- a/src/icon.c +++ b/src/icon.c @@ -115,6 +115,7 @@ cairo_surface_t *gdk_pixbuf_to_cairo_surface(GdkPixbuf *pixbuf) * * @param w a pointer to the image width, to be modified in-place * @param h a pointer to the image height, to be modified in-place + * @return TRUE if the dimensions were updated, FALSE if they were left unchanged */ static bool icon_size_clamp(int *w, int *h) { int _w = *w, _h = *h; @@ -155,11 +156,11 @@ static GdkPixbuf *icon_pixbuf_scale(GdkPixbuf *pixbuf) int h = gdk_pixbuf_get_height(pixbuf); if (icon_size_clamp(&w, &h)) { - GdkPixbuf *scaled; - scaled = gdk_pixbuf_scale_simple(pixbuf, - w, - h, - GDK_INTERP_BILINEAR); + GdkPixbuf *scaled = gdk_pixbuf_scale_simple( + pixbuf, + w, + h, + GDK_INTERP_BILINEAR); g_object_unref(pixbuf); pixbuf = scaled; }