Skip to content

Commit

Permalink
Rename "Full Sync" to "Reset Data Sync History", and don't start sync
Browse files Browse the repository at this point in the history
This allows generating debug output for full sync of a single library.

Also clarify some dialog text
  • Loading branch information
dstillman committed Jan 24, 2017
1 parent 134e77b commit cfa15a3
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 20 deletions.
9 changes: 4 additions & 5 deletions chrome/content/zotero/preferences/preferences_sync.js
Expand Up @@ -590,15 +590,15 @@ Zotero_Preferences.Sync = {
+ ps.BUTTON_POS_1_DEFAULT;
var index = ps.confirmEx(
null,
// TODO: localize
Zotero.getString('general.warning'),
"Zotero will compare all local and remote data and merge any data that does not "
+ "exist in both locations.\n\n"
// TODO: localize
"On the next sync, Zotero will compare all local and remote data and merge any "
+ "data that does not exist in both locations.\n\n"
+ "This option is not necessary during normal usage and should "
+ "generally be used only to troubleshoot specific issues as recommended "
+ "by Zotero support staff.",
buttonFlags,
"Sync",
Zotero.getString('general.reset'),
null, null, null, {}
);

Expand All @@ -611,7 +611,6 @@ Zotero_Preferences.Sync = {
yield library.save();
}
});
yield Zotero.Sync.Runner.sync();
break;

// Cancel
Expand Down
20 changes: 8 additions & 12 deletions chrome/content/zotero/preferences/preferences_sync.xul
Expand Up @@ -282,7 +282,7 @@
<column align="start" pack="start" flex="1"/>
</columns>

<rows>
<rows id="sync-reset-rows">
<!--
<row id="zotero-restore-from-server" selected="true">
<radio/>
Expand All @@ -300,21 +300,19 @@
</vbox>
</row>
-->
<row id="zotero-full-sync">
<row id="zotero-reset-data-sync-history">
<radio/>
<vbox onclick="this.previousSibling.click()">
<label value="&zotero.preferences.sync.reset.fullSync;"/>
<description>&zotero.preferences.sync.reset.fullSync.desc;</description>
<label value="&zotero.preferences.sync.reset.resetDataSyncHistory;"/>
<description>&zotero.preferences.sync.reset.resetDataSyncHistory.desc;</description>
</vbox>
</row>
</rows>
</grid>

<hbox>
<button label="&zotero.preferences.sync.reset.button;"
oncommand="Zotero_Preferences.Sync.handleSyncReset(
document.getElementById('zotero-reset-sync-group').selectedItem.parentNode.id.substr(7)
)"/>
oncommand="document.getElementById('sync-reset-rows').firstChild.firstChild.click(); Zotero_Preferences.Sync.handleSyncReset('full-sync')"/>
</hbox>
</groupbox>

Expand All @@ -327,9 +325,9 @@
<column align="start" pack="start" flex="1"/>
</columns>

<rows>
<rows id="storage-reset-rows">
<row id="zotero-reset-storage-history">
<radio/>
<radio/>
<vbox onclick="this.previousSibling.click()">
<label value="&zotero.preferences.sync.reset.resetFileSyncHistory;"/>
<description>&zotero.preferences.sync.reset.resetFileSyncHistory.desc;</description>
Expand All @@ -340,9 +338,7 @@

<hbox>
<button label="&zotero.preferences.sync.reset.button;"
oncommand="Zotero_Preferences.Sync.handleSyncReset(
document.getElementById('zotero-reset-sync-group').selectedItem.parentNode.id.substr(7)
)"/>
oncommand="document.getElementById('storage-reset-rows').firstChild.firstChild.click(); Zotero_Preferences.Sync.handleSyncReset('reset-storage-history')"/>
</hbox>
</groupbox>
</radiogroup>
Expand Down
6 changes: 3 additions & 3 deletions chrome/locale/en-US/zotero/preferences.dtd
Expand Up @@ -79,14 +79,14 @@
<!ENTITY zotero.preferences.sync.reset.warning1 "The following operations are for use only in rare, specific situations and should not be used for general troubleshooting. In many cases, resetting will cause additional problems. See ">
<!ENTITY zotero.preferences.sync.reset.warning2 "Sync Reset Options">
<!ENTITY zotero.preferences.sync.reset.warning3 " for more information.">
<!ENTITY zotero.preferences.sync.reset.fullSync "Full Sync">
<!ENTITY zotero.preferences.sync.reset.fullSync.desc "Merge local data with data from server, ignoring sync history.">
<!ENTITY zotero.preferences.sync.reset.resetDataSyncHistory "Reset Data Sync History">
<!ENTITY zotero.preferences.sync.reset.resetDataSyncHistory.desc "Merge local data with remote data, ignoring sync history">
<!ENTITY zotero.preferences.sync.reset.restoreFromServer "Restore from Zotero Server">
<!ENTITY zotero.preferences.sync.reset.restoreFromServer.desc "Erase all local Zotero data and restore from the sync server.">
<!ENTITY zotero.preferences.sync.reset.restoreToServer "Restore to Zotero Server">
<!ENTITY zotero.preferences.sync.reset.restoreToServer.desc "Erase all server data and overwrite with local Zotero data.">
<!ENTITY zotero.preferences.sync.reset.resetFileSyncHistory "Reset File Sync History">
<!ENTITY zotero.preferences.sync.reset.resetFileSyncHistory.desc "Force checking of the storage server for all local attachment files.">
<!ENTITY zotero.preferences.sync.reset.resetFileSyncHistory.desc "Check for remote copies of all local attachment files">
<!ENTITY zotero.preferences.sync.reset "Reset">
<!ENTITY zotero.preferences.sync.reset.button "Reset…">

Expand Down

0 comments on commit cfa15a3

Please sign in to comment.