"Sync with Zotero Server" -> "Sync with zotero.org"

This commit is contained in:
Dan Stillman 2016-04-08 17:03:29 -04:00
parent d2a5181637
commit b650263d66
5 changed files with 21 additions and 10 deletions

View file

@ -966,7 +966,6 @@ Zotero.Sync.Runner_Module = function (options = {}) {
// Update sync error icon
var icon = doc.getElementById('zotero-tb-sync-error');
Zotero.debug(icon + "");
this.updateErrorIcon(icon, state, errors);
// Update sync icon
@ -1119,15 +1118,21 @@ Zotero.Sync.Runner_Module = function (options = {}) {
/**
* Register label in sync icon tooltip to receive updates
* Register labels in sync icon tooltip to receive updates
*
* If no label passed, unregister current label
*
* @param {Tooltip} [label]
* @param {Tooltip} [tooltip]
*/
this.registerSyncStatusLabel = function (statusLabel, lastSyncLabel) {
_currentSyncStatusLabel = statusLabel;
_currentLastSyncLabel = lastSyncLabel;
this.registerSyncStatus = function (tooltip) {
if (tooltip) {
_currentSyncStatusLabel = tooltip.firstChild.nextSibling;
_currentLastSyncLabel = tooltip.firstChild.nextSibling.nextSibling;
}
else {
_currentSyncStatusLabel = null;
_currentLastSyncLabel = null;
}
if (_currentSyncStatusLabel) {
_updateSyncStatusLabel();
}

View file

@ -113,6 +113,12 @@ var ZoteroPane = new function()
document.getElementById('zotero-pane-stack').setAttribute('oldsearchfield', 'true')
}
// Set the sync tooltip label
Components.utils.import("resource://zotero/config.js");
document.getElementById('zotero-tb-sync-label').value = Zotero.getString(
'sync.syncWith', ZOTERO_CONFIG.DOMAIN_NAME
);
if (Zotero.isStandalone) {
document.getElementById('zotero-tb-feed-add-fromPage').hidden = true;
document.getElementById('zotero-tb-feed-add-fromPage-menu').hidden = true;

View file

@ -237,10 +237,10 @@
oncommand="Zotero.Sync.Server.canAutoResetClient = true; Zotero.Sync.Server.manualSyncRequired = false; Zotero.Sync.Runner.sync()">
<tooltip
id="zotero-tb-sync-tooltip"
onpopupshowing="Zotero.Sync.Runner.registerSyncStatusLabel(this.firstChild.nextSibling, this.firstChild.nextSibling.nextSibling)"
onpopuphiding="Zotero.Sync.Runner.registerSyncStatusLabel()"
onpopupshowing="Zotero.Sync.Runner.registerSyncStatus(this)"
onpopuphiding="Zotero.Sync.Runner.registerSyncStatus()"
noautohide="true">
<label value="&zotero.sync.button;"/>
<label id="zotero-tb-sync-label"/>
<label id="zotero-tb-sync-status" hidden="true"/>
<label id="zotero-tb-sync-last-sync"/>
</tooltip>

View file

@ -237,7 +237,6 @@
<!ENTITY zotero.integration.references.label "References in Bibliography">
<!ENTITY zotero.sync.button "Sync with Zotero Server">
<!ENTITY zotero.sync.error "Sync Error">
<!ENTITY zotero.sync.storage.progress "Progress:">
<!ENTITY zotero.sync.storage.downloads "Downloads:">

View file

@ -809,6 +809,7 @@ styles.abbreviations.parseError = The abbreviations file "%1$S" is not valid JS
styles.abbreviations.missingInfo = The abbreviations file "%1$S" does not specify a complete info block.
sync.sync = Sync
sync.syncWith = Sync with %S
sync.cancel = Cancel Sync
sync.openSyncPreferences = Open Sync Preferences
sync.resetGroupAndSync = Reset Group and Sync