From e8f7d2320ea63275086ae546c9e07da88e64081a Mon Sep 17 00:00:00 2001 From: Simon Kornblith Date: Fri, 23 Mar 2007 14:37:29 +0000 Subject: [PATCH] fix locator issues with multiple citations --- chrome/content/zotero/addCitationDialog.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/chrome/content/zotero/addCitationDialog.js b/chrome/content/zotero/addCitationDialog.js index 8b784d18c0..aca11aafb2 100644 --- a/chrome/content/zotero/addCitationDialog.js +++ b/chrome/content/zotero/addCitationDialog.js @@ -114,7 +114,7 @@ var Zotero_Citation_Dialog = new function () { // flag _itemLocators[itemID] = document.getElementById("tree-locator").value; - _itemLocatorTypes[itemID] = document.getElementById("tree-locator-type").selectedItem.value; + _itemLocatorTypes[itemID] = document.getElementById("tree-locator-type").selectedIndex; document.getElementById("tree-locator").value = ""; } @@ -130,6 +130,9 @@ var Zotero_Citation_Dialog = new function () { } function accept() { + // use to map selectedIndexes back to "p"/"g"/"l" + var locatorTypeElements = document.getElementById("tree-locator-type").getElementsByTagName("menuitem"); + var io = window.arguments[0].wrappedJSObject; if(_multipleSourcesOn) { treeItemSelected(); // store locator info @@ -145,7 +148,7 @@ var Zotero_Citation_Dialog = new function () { for(var i=0; i