[gnome-commander/gcmd-1-3] Yet another fix to avoid calling IMAGE_get_pixmap_and_mask() twice when displaying file icons
- From: Piotr Eljasiak <epiotr src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gnome-commander/gcmd-1-3] Yet another fix to avoid calling IMAGE_get_pixmap_and_mask() twice when displaying file icons
- Date: Sat, 12 Sep 2009 17:06:29 +0000 (UTC)
commit a595aecc44a123da1336d2058dab73b2657ade2d
Author: Piotr Eljasiak <epiotr src gnome org>
Date: Sat Sep 12 18:54:09 2009 +0200
Yet another fix to avoid calling IMAGE_get_pixmap_and_mask() twice when displaying file icons
src/gnome-cmd-file-list.cc | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/gnome-cmd-file-list.cc b/src/gnome-cmd-file-list.cc
index 194dbcd..c32377c 100644
--- a/src/gnome-cmd-file-list.cc
+++ b/src/gnome-cmd-file-list.cc
@@ -1482,9 +1482,11 @@ inline void add_file_to_clist (GnomeCmdFileList *fl, GnomeCmdFile *f, gint in_ro
// If the use wants icons to show file types set it now
if (gnome_cmd_data.layout != GNOME_CMD_LAYOUT_TEXT)
{
- gtk_clist_set_pixmap (clist, row, 0,
- gnome_cmd_file_get_type_pixmap (f),
- gnome_cmd_file_get_type_mask (f));
+ GdkPixmap *pixmap;
+ GdkBitmap *mask;
+
+ if (gnome_cmd_file_get_type_pixmap_and_mask (f, &pixmap, &mask))
+ gtk_clist_set_pixmap (clist, row, 0, pixmap, mask);
}
// If we have been waiting for this file to show up, focus it
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]