GtkWindow: Handle non-square icons with height > width correctly

This commit is contained in:
Christian Stadelmann
2018-06-03 21:05:46 +02:00
parent 7951f0e9a9
commit d4feb8929e

View File

@@ -4576,7 +4576,8 @@ icon_from_list (GList *list,
for (l = list; l; l = l->next)
{
pixbuf = list->data;
if (gdk_pixbuf_get_width (pixbuf) <= size)
if (gdk_pixbuf_get_width (pixbuf) <= size &&
gdk_pixbuf_get_height (pixbuf) <= size)
{
best = g_object_ref (pixbuf);
break;