From 983673e354615f3393e1fd4ff77e788d660ba731 Mon Sep 17 00:00:00 2001 From: Simon Kornblith Date: Sat, 6 Nov 2010 22:20:53 +0000 Subject: [PATCH] - don't export duplicate items - don't export top-level collection name - use file name for name of collection when importing --- chrome/content/zotero/fileInterface.js | 16 ++++++++++++++-- .../zotero/xpcom/translation/item_local.js | 16 +++++++++------- .../zotero/xpcom/translation/translate.js | 2 -- 3 files changed, 23 insertions(+), 11 deletions(-) diff --git a/chrome/content/zotero/fileInterface.js b/chrome/content/zotero/fileInterface.js index 9bdf2c5ac4..87f51cb366 100644 --- a/chrome/content/zotero/fileInterface.js +++ b/chrome/content/zotero/fileInterface.js @@ -258,9 +258,21 @@ var Zotero_File_Interface = new function() { function _importTranslatorsAvailable(translation, translators) { if(translators.length) { + if(translation.location instanceof Components.interfaces.nsIFile) { + var collectionName = translation.location.leafName.substr(0, translation.location.leafName.lastIndexOf(".")); + var allCollections = Zotero.getCollections(); + for(var i=0; i