summaryrefslogtreecommitdiff
path: root/src/xfdesktop-file-utils.c
diff options
context:
space:
mode:
authorEric Koegel <eric.koegel@gmail.com>2013-08-25 14:08:37 +0300
committerEric Koegel <eric.koegel@gmail.com>2013-08-25 14:12:07 +0300
commitde26505ba425ca939241e0c51b860c5763850386 (patch)
tree9c57fe09b0a4351229cf344fa60accc9bb6aec16 /src/xfdesktop-file-utils.c
parent21fe3ab4185b7eba72b5554f4645c8945be3da27 (diff)
downloadxfdesktop-de26505ba425ca939241e0c51b860c5763850386.tar.gz
Better icon pixbuf caching
With the inclusion of tooltip pixbuf previews the icon pixbuf would get recreated every time the tooltip pixbuf was generated. So now it will cache both the normal size icon pixbuf and the tooltip pixbuf. The pixbufs are stored in the base icon so that all the different icon types don't have to do the same redundant checks.
Diffstat (limited to 'src/xfdesktop-file-utils.c')
-rw-r--r--src/xfdesktop-file-utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/xfdesktop-file-utils.c b/src/xfdesktop-file-utils.c
index ba0e753d..248df593 100644
--- a/src/xfdesktop-file-utils.c
+++ b/src/xfdesktop-file-utils.c
@@ -584,7 +584,7 @@ xfdesktop_file_utils_add_emblems(GdkPixbuf *pix, GList *emblems)
pix_width = gdk_pixbuf_get_width(pix);
pix_height = gdk_pixbuf_get_height(pix);
- emblem_size = MIN(pix_width, pix_height) / 3;
+ emblem_size = MIN(pix_width, pix_height) / 2;
/* render up to four emblems for sizes from 48 onwards, else up to 2 emblems */
max_emblems = (pix_height < 48 && pix_width < 48) ? 2 : 4;