www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit 0c60911fd1928c159087056be571ce98ec89f7c3
parent 30f5679ec8aee72cd9461a528cf3af8d593ae04c
Author: Dan Stillman <dstillman@zotero.org>
Date:   Tue,  5 Mar 2013 03:19:29 -0500

Tweaks to @gracile-fr's localization changes

Addresses #264

Diffstat:
Mchrome/content/zotero/bindings/merge.xml | 2+-
Mchrome/content/zotero/merge.xul | 2+-
Mchrome/content/zotero/xpcom/storage/webdav.js | 25+++++++++++++------------
Dchrome/locale/en-US/zotero/merge.dtd | 4----
Mchrome/locale/en-US/zotero/zotero.dtd | 4++++
5 files changed, 19 insertions(+), 18 deletions(-)

diff --git a/chrome/content/zotero/bindings/merge.xml b/chrome/content/zotero/bindings/merge.xml @@ -478,7 +478,7 @@ <xul:box id="object-placeholder"/> <xul:hbox id="delete-box" hidden="true" flex="1" onclick="document.getBindingParent(this).chooseObj(this)"> - <xul:label value="zotero.merge.deleted"/> + <xul:label value="&zotero.merge.deleted;"/> </xul:hbox> </xul:groupbox> </content> diff --git a/chrome/content/zotero/merge.xul b/chrome/content/zotero/merge.xul @@ -28,7 +28,7 @@ <?xml-stylesheet href="chrome://zotero/skin/zotero.css" type="text/css"?> <?xml-stylesheet href="chrome://zotero/skin/merge.css" type="text/css"?> -<!DOCTYPE window SYSTEM "chrome://zotero/locale/merge.dtd"> +<!DOCTYPE window SYSTEM "chrome://zotero/locale/zotero.dtd"> <wizard id="zotero-merge-window" diff --git a/chrome/content/zotero/xpcom/storage/webdav.js b/chrome/content/zotero/xpcom/storage/webdav.js @@ -25,13 +25,6 @@ Zotero.Sync.Storage.WebDAV = (function () { - // TEMP - //This doesn't work (Localized string not available for sync.storage...): - //var _defaultError = Zotero.getString('sync.storage.error.webdav.default'); - //var _defaultErrorRestart = Zotero.getString('sync.storage.error.webdav.defaultRestart', Zotero.appName); - var _defaultError = "A WebDAV file sync error occurred. Please try syncing again.\n\nIf you receive this message repeatedly, check your WebDAV server settings in the Sync pane of the Zotero preferences."; - var _defaultErrorRestart = "A WebDAV file sync error occurred. Please restart " + Zotero.appName + " and try syncing again.\n\nIf you receive this message repeatedly, check your WebDAV server settings in the Sync pane of the Zotero preferences."; - var _initialized = false; var _parentURI; var _rootURI; @@ -112,7 +105,7 @@ Zotero.Sync.Storage.WebDAV = (function () { Components.utils.reportError(msg); return deleteStorageFiles([item.key + ".prop"]) .then(function (results) { - throw new Error(_defaultError); + throw new Error(Zotero.Sync.Storage.WebDAV.defaultError); }); } @@ -642,13 +635,21 @@ Zotero.Sync.Storage.WebDAV = (function () { var obj = new Zotero.Sync.Storage.Mode; obj.name = "WebDAV"; + Object.defineProperty(obj, "defaultError", { + get: function () Zotero.getString('sync.storage.error.webdav.default') + }); + + Object.defineProperty(obj, "defaultErrorRestart", { + get: function () Zotero.getString('sync.storage.error.webdav.defaultRestart', Zotero.appName) + }); + Object.defineProperty(obj, "includeUserFiles", { get: function () { return Zotero.Prefs.get("sync.storage.enabled") && Zotero.Prefs.get("sync.storage.protocol") == 'webdav'; } }); obj.includeGroupItems = false; - + Object.defineProperty(obj, "_verified", { get: function () Zotero.Prefs.get("sync.storage.verified") }); @@ -882,7 +883,7 @@ Zotero.Sync.Storage.WebDAV = (function () { + " in Zotero.Sync.Storage.WebDAV.downloadFile()"; Zotero.debug(msg, 1); Components.utils.reportError(msg); - deferred.reject(_defaultError); + deferred.reject(Zotero.Sync.Storage.WebDAV.defaultError); return; } @@ -1032,7 +1033,7 @@ Zotero.Sync.Storage.WebDAV = (function () { var msg = "Unexpected error code " + req.status + " uploading storage success file"; Zotero.debug(msg, 2); Components.utils.reportError(msg); - throw _defaultError; + throw Zotero.Sync.Storage.WebDAV.defaultError; }); }; @@ -1056,7 +1057,7 @@ Zotero.Sync.Storage.WebDAV = (function () { + "for OPTIONS request caching WebDAV credentials"; Zotero.debug(msg, 1); Components.utils.reportError(msg); - throw new Error(_defaultErrorRestart); + throw new Error(Zotero.Sync.Storage.WebDAV.defaultErrorRestart); } throw e; }); diff --git a/chrome/locale/en-US/zotero/merge.dtd b/chrome/locale/en-US/zotero/merge.dtd @@ -1,3 +0,0 @@ -<!ENTITY zotero.merge.title "Conflict Resolution"> -<!ENTITY zotero.merge.of "of"> -<!ENTITY zotero.merge.deleted "Deleted"> -\ No newline at end of file diff --git a/chrome/locale/en-US/zotero/zotero.dtd b/chrome/locale/en-US/zotero/zotero.dtd @@ -233,6 +233,10 @@ <!ENTITY zotero.sync.longTagFixer.uncheckedTagsNotSaved "Unchecked tags will not be saved."> <!ENTITY zotero.sync.longTagFixer.tagWillBeDeleted "The tag will be deleted from all items."> +<!ENTITY zotero.merge.title "Conflict Resolution"> +<!ENTITY zotero.merge.of "of"> +<!ENTITY zotero.merge.deleted "Deleted"> + <!ENTITY zotero.proxy.recognized.title "Proxy Recognized"> <!ENTITY zotero.proxy.recognized.warning "Only add proxies linked from your library, school, or corporate website"> <!ENTITY zotero.proxy.recognized.warning.secondary "Adding other proxies allows malicious sites to masquerade as sites you trust.">