www

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

commit 30ae61d60ee362834a5bb0f89ea513945f550db1
parent 45357bdb85263b6c991fd81ce965291174e36d56
Author: Dan Stillman <dstillman@zotero.org>
Date:   Wed, 18 Oct 2017 04:08:40 -0400

More 2x icon fixes

Follow-up to 5b2af4845b

Diffstat:
Mchrome/content/zotero/bindings/itembox.xml | 4++--
Mchrome/content/zotero/bindings/tagsbox.xml | 2+-
Mchrome/content/zotero/itemPane.js | 2+-
Mchrome/content/zotero/selectItemsDialog.xul | 2--
Mchrome/content/zotero/xpcom/collectionTreeView.js | 2+-
Mchrome/content/zotero/xpcom/data/collection.js | 3++-
Mchrome/content/zotero/xpcom/data/search.js | 2+-
Mchrome/content/zotero/zoteroPane.xul | 1-
Mchrome/skin/default/zotero/zotero.css | 12++++--------
9 files changed, 12 insertions(+), 18 deletions(-)

diff --git a/chrome/content/zotero/bindings/itembox.xml b/chrome/content/zotero/bindings/itembox.xml @@ -933,7 +933,7 @@ // Switch to single-field mode if (fieldMode == 1) { - button.style.backgroundImage = `url("chrome://zotero/skin/textfield-dual${Zotero.hiDPISuffix}.png")`; + button.style.background = `url("chrome://zotero/skin/textfield-dual${Zotero.hiDPISuffix}.png") center/21px auto no-repeat`; button.setAttribute('tooltiptext', Zotero.getString('pane.item.switchFieldMode.two')); lastName.setAttribute('fieldMode', '1'); button.setAttribute('onclick', "document.getBindingParent(this).switchCreatorMode(Zotero.getAncestorByTagName(this, 'row'), 0, false, true)"); @@ -966,7 +966,7 @@ } // Switch to two-field mode else { - button.style.backgroundImage = `url("chrome://zotero/skin/textfield-single${Zotero.hiDPISuffix}.png")`; + button.style.background = `url("chrome://zotero/skin/textfield-single${Zotero.hiDPISuffix}.png") center/21px auto no-repeat`; button.setAttribute('tooltiptext', Zotero.getString('pane.item.switchFieldMode.one')); lastName.setAttribute('fieldMode', '0'); button.setAttribute('onclick', "document.getBindingParent(this).switchCreatorMode(Zotero.getAncestorByTagName(this, 'row'), 1, false, true)"); diff --git a/chrome/content/zotero/bindings/tagsbox.xml b/chrome/content/zotero/bindings/tagsbox.xml @@ -321,7 +321,7 @@ iconFile += '-automatic'; icon.setAttribute('tooltiptext', Zotero.getString('pane.item.tags.icon.automatic')); } - icon.setAttribute('src', 'chrome://zotero/skin/' + iconFile + '.png'); + icon.setAttribute('src', `chrome://zotero/skin/${iconFile}${Zotero.hiDPISuffix}.png`); // "-" button if (this.editable) { diff --git a/chrome/content/zotero/itemPane.js b/chrome/content/zotero/itemPane.js @@ -137,7 +137,7 @@ var ZoteroItemPane = new function() { var icon = document.createElement('image'); icon.className = "zotero-box-icon"; - icon.setAttribute('src','chrome://zotero/skin/treeitem-note.png'); + icon.setAttribute('src', `chrome://zotero/skin/treeitem-note${Zotero.hiDPISuffix}.png`); var label = document.createElement('label'); label.className = "zotero-box-label"; diff --git a/chrome/content/zotero/selectItemsDialog.xul b/chrome/content/zotero/selectItemsDialog.xul @@ -236,14 +236,12 @@ id="zotero-items-column-hasAttachment" hidden="true" class="treecol-image" label="&zotero.tabs.attachments.label;" - src="chrome://zotero/skin/attach-small.png" zotero-persist="width ordinal hidden sortActive sortDirection"/> <splitter class="tree-splitter"/> <treecol id="zotero-items-column-numNotes" hidden="true" class="treecol-image" label="&zotero.tabs.notes.label;" - src="chrome://zotero/skin/treeitem-note-small.png" zotero-persist="width ordinal hidden sortActive sortDirection"/> </treecols> <treechildren/> diff --git a/chrome/content/zotero/xpcom/collectionTreeView.js b/chrome/content/zotero/xpcom/collectionTreeView.js @@ -769,7 +769,7 @@ Zotero.CollectionTreeView.prototype.getImageSrc = function(row, col) case 'search': // Keep in sync with Zotero.(Collection|Search).prototype.treeViewImage if (Zotero.isMac) { - return "chrome://zotero-platform/content/treesource-" + collectionType + ".png"; + return `chrome://zotero-platform/content/treesource-${collectionType}${Zotero.hiDPISuffix}.png`; } break; diff --git a/chrome/content/zotero/xpcom/data/collection.js b/chrome/content/zotero/xpcom/data/collection.js @@ -91,8 +91,9 @@ Zotero.defineProperty(Zotero.Collection.prototype, 'treeViewID', { Zotero.defineProperty(Zotero.Collection.prototype, 'treeViewImage', { get: function () { + // Keep in sync with collectionTreeView::getImageSrc() if (Zotero.isMac) { - return "chrome://zotero-platform/content/treesource-collection.png"; + return `chrome://zotero-platform/content/treesource-collection${Zotero.hiDPISuffix}.png`; } return "chrome://zotero/skin/treesource-collection" + Zotero.hiDPISuffix + ".png"; } diff --git a/chrome/content/zotero/xpcom/data/search.js b/chrome/content/zotero/xpcom/data/search.js @@ -101,7 +101,7 @@ Zotero.defineProperty(Zotero.Search.prototype, 'treeViewID', { Zotero.defineProperty(Zotero.Search.prototype, 'treeViewImage', { get: function () { if (Zotero.isMac) { - return "chrome://zotero-platform/content/treesource-search.png"; + return `chrome://zotero-platform/content/treesource-search${Zotero.hiDPISuffix}.png`; } return "chrome://zotero/skin/treesource-search" + Zotero.hiDPISuffix + ".png"; } diff --git a/chrome/content/zotero/zoteroPane.xul b/chrome/content/zotero/zoteroPane.xul @@ -559,7 +559,6 @@ id="zotero-items-column-numNotes" disabled-in="feed" class="treecol-image" label="&zotero.tabs.notes.label;" - src="chrome://zotero/skin/treeitem-note-small.png" zotero-persist="width ordinal hidden sortActive sortDirection"/> </treecols> <treechildren ondragstart="ZoteroPane_Local.itemsView.onDragStart(event)" diff --git a/chrome/skin/default/zotero/zotero.css b/chrome/skin/default/zotero/zotero.css @@ -273,16 +273,12 @@ label.zotero-text-link { } .zotero-clicky-minus { - background-image: url('chrome://zotero/skin/minus.png') !important; - background-position: center !important; - background-repeat: no-repeat !important; + background: url(chrome://zotero/skin/minus.png) center/auto 18px no-repeat !important; border: 0px !important; } .zotero-clicky-plus { - background-image: url('chrome://zotero/skin/plus.png') !important; - background-position: center !important; - background-repeat: no-repeat !important; + background: url(chrome://zotero/skin/plus.png) center/auto 18px no-repeat !important; border: 0px !important; } @@ -465,8 +461,8 @@ label.zotero-text-link { /* BEGIN 2X BLOCK -- DO NOT EDIT MANUALLY -- USE 2XIZE */ @media (min-resolution: 1.5dppx) { #zotero-toolbar-save-button,#zotero-toolbar-save-button-single { list-style-image: url("chrome://zotero/skin/treeitem-webpage@2x.png"); } - .zotero-clicky-minus { background-image: url('chrome://zotero/skin/minus@2x.png') !important; } - .zotero-clicky-plus { background-image: url('chrome://zotero/skin/plus@2x.png') !important; } + .zotero-clicky-minus { background: url(chrome://zotero/skin/minus@2x.png) center/auto 18px no-repeat !important; } + .zotero-clicky-plus { background: url(chrome://zotero/skin/plus@2x.png) center/auto 18px no-repeat !important; } .zotero-clicky-minus:not([disabled=true]):active { background-image: url('chrome://zotero/skin/minus-active@2x.png') !important; } .zotero-clicky-plus:not([disabled=true]):active { background-image: url('chrome://zotero/skin/plus-active@2x.png') !important; } .zotero-scrape-popup-library { list-style-image: url('chrome://zotero/skin/treesource-library@2x.png'); }