www

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

commit 456406fc1072d91215f60c8efee5ea4865f61d04
parent c22c87a0535d6c14a44687e3b859a58042672541
Author: Dan Stillman <dstillman@zotero.org>
Date:   Wed, 12 Oct 2011 08:48:47 +0000

Increase max length of duplicate detection field selector menu items, and display tooltip if still cut off


Diffstat:
Mchrome/content/zotero/bindings/itembox.xml | 8+++++++-
1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/chrome/content/zotero/bindings/itembox.xml b/chrome/content/zotero/bindings/itembox.xml @@ -442,7 +442,11 @@ for each(var v in this._fieldAlternatives[fieldName]) { var menuitem = document.createElement("menuitem"); - menuitem.setAttribute('label', Zotero.Utilities.ellipsize(v, 40)); + var sv = Zotero.Utilities.ellipsize(v, 60); + menuitem.setAttribute('label', sv); + if (v != sv) { + menuitem.setAttribute('tooltiptext', v); + } menuitem.setAttribute('fieldName', fieldName); menuitem.setAttribute('originalValue', v); menuitem.setAttribute( @@ -520,6 +524,7 @@ this._creatorCount = 0; var num = this.item.numCreators(); if (num > 0) { + // Limit number of creators display var max = Math.min(num, this._initialVisibleCreators); // If fewer than five more, just display if (num < max + 5 || this._displayAllCreators) { @@ -529,6 +534,7 @@ this.addCreatorRow(this.item.getCreator(i).ref, this.item.getCreator(i).creatorTypeID); + // Display "+" button on all but last row if (i == max - 2) { this.disableCreatorAddButtons(); }