From b75b36fa771de78982cc37b986059e0a0ab621a4 Mon Sep 17 00:00:00 2001 From: Simon Kornblith Date: Wed, 3 Aug 2011 20:51:26 +0000 Subject: [PATCH] Closes #1875, [PATCH] Add ISI to MIME type-detected imports Thanks to ajlyon for the patch --- chrome/content/zotero/xpcom/mimeTypeHandler.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/chrome/content/zotero/xpcom/mimeTypeHandler.js b/chrome/content/zotero/xpcom/mimeTypeHandler.js index b0a9ace15a..d5467e6a6d 100644 --- a/chrome/content/zotero/xpcom/mimeTypeHandler.js +++ b/chrome/content/zotero/xpcom/mimeTypeHandler.js @@ -52,6 +52,8 @@ Zotero.MIMETypeHandler = new function () { if(Zotero.Prefs.get("parseEndNoteMIMETypes")) { this.addHandler("application/x-endnote-refer", _importHandler, true); this.addHandler("application/x-research-info-systems", _importHandler, true); + // Add ISI + this.addHandler("application/x-inst-for-Scientific-info", _importHandler, true); // // And some non-standard ones // @@ -90,9 +92,9 @@ Zotero.MIMETypeHandler = new function () { /** - * Handles Refer/RIS MIME types - * @param {String} string The Refer/RIS formatted records - * @param {String} uri The URI from which the Refer/RIS formatted records were downloaded + * Handles Refer/RIS/ISI MIME types + * @param {String} string The Refer/RIS/ISI formatted records + * @param {String} uri The URI from which the Refer/RIS/ISI formatted records were downloaded */ function _importHandler(string, uri, contentType, channel) { var win = channel.notificationCallbacks.getInterface(Components.interfaces.nsIDOMWindow).top; @@ -171,7 +173,7 @@ Zotero.MIMETypeHandler = new function () { if(!translators.length) { // we lied. we can't really translate this file. frontWindow.Zotero_Browser.progress.close(); - throw "No translator found for handled RIS or Refer file" + throw "No translator found for handled RIS, Refer or ISI file" } // translate using first available @@ -348,4 +350,4 @@ Zotero.MIMETypeHandler = new function () { this._storageStream.close(); } -} \ No newline at end of file +}