commit c5581112692fce06ce226124b6c3862b51d1a200
parent 14b62e27e24a905e72aba5b512e064fda078dfa7
Author: Dan Stillman <dstillman@zotero.org>
Date: Wed, 28 Apr 2010 20:43:06 +0000
- Add a Zotero.wait() to translator caching, which I may or may not have tried before and which may or may not improve Firefox responsiveness during translator caching
- Only check first 1024 chars of translator file for JSON
Not going on the 2.0 branch
Diffstat:
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/chrome/content/zotero/xpcom/translate.js b/chrome/content/zotero/xpcom/translate.js
@@ -78,6 +78,8 @@ Zotero.Translators = new function() {
}
}
}
+
+ Zotero.wait();
i++;
}
@@ -226,7 +228,7 @@ Zotero.Translators = new function() {
*/
Zotero.Translator = function(file) {
// Maximum length for the info JSON in a translator
- const MAX_INFO_LENGTH = 4096;
+ const MAX_INFO_LENGTH = 1024;
const infoRe = /{(?:(?:"(?:[^"\r\n]*(?:\\")?)*")*[^}"]*)*}/;
this.file = file;