nautilus r14185 - in trunk: . libnautilus-private
- From: cneumair svn gnome org
- To: svn-commits-list gnome org
- Subject: nautilus r14185 - in trunk: . libnautilus-private
- Date: Thu, 22 May 2008 17:36:27 +0000 (UTC)
Author: cneumair
Date: Thu May 22 17:36:27 2008
New Revision: 14185
URL: http://svn.gnome.org/viewvc/nautilus?rev=14185&view=rev
Log:
2008-05-22 Christian Neumair <cneumair gnome org>
* libnautilus-private/nautilus-file.c (nautilus_file_get_icon):
Fix frame size calculation.
Modified:
trunk/ChangeLog
trunk/libnautilus-private/nautilus-file.c
Modified: trunk/libnautilus-private/nautilus-file.c
==============================================================================
--- trunk/libnautilus-private/nautilus-file.c (original)
+++ trunk/libnautilus-private/nautilus-file.c Thu May 22 17:36:27 2008
@@ -3392,14 +3392,14 @@
w = gdk_pixbuf_get_width (raw_pixbuf);
h = gdk_pixbuf_get_height (raw_pixbuf);
- /* These compensates for frame size which will be added on the raw image */
- s = MAX (NAUTILUS_THUMBNAIL_FRAME_LEFT + w + NAUTILUS_THUMBNAIL_FRAME_RIGHT,
- NAUTILUS_THUMBNAIL_FRAME_TOP + h + NAUTILUS_THUMBNAIL_FRAME_BOTTOM);
+ s = MAX (w, h);
scale = (double)modified_size / s;
+ /* These compensate for the size of the frame which will be added around the raw image */
scaled_pixbuf = gdk_pixbuf_scale_simple (raw_pixbuf,
- w * scale, h * scale,
+ NAUTILUS_THUMBNAIL_FRAME_LEFT + w * scale + NAUTILUS_THUMBNAIL_FRAME_RIGHT,
+ NAUTILUS_THUMBNAIL_FRAME_TOP + h * scale + NAUTILUS_THUMBNAIL_FRAME_BOTTOM,
GDK_INTERP_BILINEAR);
nautilus_thumbnail_frame_image (&scaled_pixbuf);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]