From 1e45aed75348563bf56ad743f5b34556de8f1bbf Mon Sep 17 00:00:00 2001 From: J Richard Snape Date: Thu, 18 Apr 2013 12:18:13 +0100 Subject: [PATCH] Fix issue #251 Two changes needed to cope with shift-enter being pressed both with and without changes to current creator row Signed-off-by: J Richard Snape --- chrome/content/zotero/bindings/itembox.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/chrome/content/zotero/bindings/itembox.xml b/chrome/content/zotero/bindings/itembox.xml index f463ccf6e..62eeb6739 100644 --- a/chrome/content/zotero/bindings/itembox.xml +++ b/chrome/content/zotero/bindings/itembox.xml @@ -552,7 +552,7 @@ this._displayAllCreators = true; if (this._addCreatorRow) { - this.addCreatorRow(false, false, true); + this.addCreatorRow(false, this.item.getCreator(max-1).creatorTypeID, true); this._addCreatorRow = false; this.disableCreatorAddButtons(); } @@ -1555,8 +1555,8 @@ this._focusNextField(this._dynamicFields, this._lastTabIndex, false); } else { - // TODO: should use current creator type - this.addCreatorRow(false, false, true); + var creatorFields = this.getCreatorFields(Zotero.getAncestorByTagName(target, 'row')); + this.addCreatorRow(false, creatorFields.creatorTypeID, true); } } // Value has changed