diff options
author | Gaël Bonithon <gael@xfce.org> | 2021-12-22 19:15:55 +0100 |
---|---|---|
committer | Gaël Bonithon <gael@xfce.org> | 2021-12-22 19:20:25 +0100 |
commit | f0bc4cc996c8363d92180c9f60d9e6f1ad1cf7b2 (patch) | |
tree | 86ad4b110ba34f7e86eaa6453aea3c6321db21dd /tumbler | |
parent | 9bd5c1084f3014ed059b8726b0df77d1b2957c94 (diff) | |
download | tumbler-f0bc4cc996c8363d92180c9f60d9e6f1ad1cf7b2.tar.gz |
Fix mistake in previous commit
I took the exception for the rule: let's hope this time it's good.
Diffstat (limited to 'tumbler')
-rw-r--r-- | tumbler/tumbler-util.c | 7 | ||||
-rw-r--r-- | tumbler/tumbler-util.h | 2 |
2 files changed, 6 insertions, 3 deletions
diff --git a/tumbler/tumbler-util.c b/tumbler/tumbler-util.c index 046b42e..9d6fad0 100644 --- a/tumbler/tumbler-util.c +++ b/tumbler/tumbler-util.c @@ -173,16 +173,19 @@ void tumbler_util_size_prepared (GdkPixbufLoader *loader, gint source_width, gint source_height, - TumblerThumbnailFlavor *flavor) + TumblerThumbnail *thumbnail) { + TumblerThumbnailFlavor *flavor; gdouble hratio, wratio; gint dest_width, dest_height; g_return_if_fail (GDK_IS_PIXBUF_LOADER (loader)); - g_return_if_fail (TUMBLER_IS_THUMBNAIL_FLAVOR (flavor)); + g_return_if_fail (TUMBLER_IS_THUMBNAIL (thumbnail)); /* get the destination size */ + flavor = tumbler_thumbnail_get_flavor (thumbnail); tumbler_thumbnail_flavor_get_size (flavor, &dest_width, &dest_height); + g_object_unref (flavor); if (source_width <= dest_width && source_height <= dest_height) { diff --git a/tumbler/tumbler-util.h b/tumbler/tumbler-util.h index c55245d..be030cc 100644 --- a/tumbler/tumbler-util.h +++ b/tumbler/tumbler-util.h @@ -37,7 +37,7 @@ gboolean tumbler_util_guess_is_sparse (TumblerFileInfo *info); void tumbler_util_size_prepared (GdkPixbufLoader *loader, gint source_width, gint source_height, - TumblerThumbnailFlavor *flavor); + TumblerThumbnail *thumbnail); GdkPixbuf *tumbler_util_scale_pixbuf (GdkPixbuf *source, gint dest_width, |