[gnome-documents] documents: use doc pixbufs without effects to build collection icons
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-documents] documents: use doc pixbufs without effects to build collection icons
- Date: Wed, 16 Nov 2011 02:47:37 +0000 (UTC)
commit da9adedbb04180587bf7eb3d6f556c056cf35beb
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Tue Nov 15 13:16:42 2011 -0500
documents: use doc pixbufs without effects to build collection icons
We don't want the thumbnail frame or the category emblems to show up in
the collection icon miniatures.
src/documents.js | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/src/documents.js b/src/documents.js
index 89f885b..6a0a14f 100644
--- a/src/documents.js
+++ b/src/documents.js
@@ -244,7 +244,7 @@ CollectionIconWatcher.prototype = {
this._docs.forEach(
function(doc) {
- pixbufs.push(doc.pixbuf);
+ pixbufs.push(doc.pristinePixbuf);
});
this._pixbuf = Gd.create_collection_icon(Utils.getIconSize(), pixbufs);
@@ -283,6 +283,7 @@ DocCommon.prototype = {
this.resourceUrn = null;
this.favorite = null;
this.pixbuf = null;
+ this.pristinePixbuf = null;
this.defaultAppName = null;
this.mimeType = null;
@@ -525,6 +526,9 @@ DocCommon.prototype = {
let pixbuf = this.pixbuf;
let activeItem;
+ // save the pixbuf before modifications, to use in collection icons
+ this.pristinePixbuf = pixbuf;
+
activeItem = Global.searchCategoryManager.getActiveItem();
if (this.favorite &&
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]