www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit eb94d648d7da5262796593517771ff939d130baa
parent c02755cb596f5ffa2f8b24af976ac50b0c73de21
Author: Dan Stillman <dstillman@zotero.org>
Date:   Tue,  3 Oct 2006 16:25:16 +0000

Closes #300, when a webpage snapshot is selected in "related" tab, disk icon appears


Diffstat:
Mchrome/content/zotero/bindings/relatedbox.xml | 24+++++++++++++++++++++++-
Dchrome/skin/default/zotero/item-attachments-add.png | 0
Dchrome/skin/default/zotero/treeitem-attachment.png | 0
3 files changed, 23 insertions(+), 1 deletion(-)

diff --git a/chrome/content/zotero/bindings/relatedbox.xml b/chrome/content/zotero/bindings/relatedbox.xml @@ -58,7 +58,29 @@ for(var i = 0; i < seealso.length; i++) { var icon= document.createElement("image"); - icon.setAttribute('src','chrome://zotero/skin/treeitem-'+Zotero.ItemTypes.getName(seealso[i].getType())+'.png'); + var type = Zotero.ItemTypes.getName(seealso[i].getType()); + if (type=='attachment') + { + switch (seealso[i].getAttachmentLinkMode()) + { + case Zotero.Attachments.LINK_MODE_LINKED_URL: + type += '-web-link'; + break; + + case Zotero.Attachments.LINK_MODE_IMPORTED_URL: + type += '-snapshot'; + break; + + case Zotero.Attachments.LINK_MODE_LINKED_FILE: + type += '-link'; + break; + + case Zotero.Attachments.LINK_MODE_IMPORTED_FILE: + type += '-file'; + break; + } + } + icon.setAttribute('src','chrome://zotero/skin/treeitem-' + type + '.png'); var label = document.createElement("label"); label.setAttribute('value', seealso[i].getField('title')); diff --git a/chrome/skin/default/zotero/item-attachments-add.png b/chrome/skin/default/zotero/item-attachments-add.png Binary files differ. diff --git a/chrome/skin/default/zotero/treeitem-attachment.png b/chrome/skin/default/zotero/treeitem-attachment.png Binary files differ.