summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjohnnyg@chromium.org <johnnyg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-11 01:41:34 +0000
committerjohnnyg@chromium.org <johnnyg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-11 01:41:34 +0000
commit69c03be52ad42b06ff1d29db55245c2b3ca6bbe8 (patch)
treee5495caa9d8928049a94ecdf7c381dc2858ab494
parent1c54823d55bfe39a4caa679f5f867b0c96368e05 (diff)
downloadchromium_src-69c03be52ad42b06ff1d29db55245c2b3ca6bbe8.zip
chromium_src-69c03be52ad42b06ff1d29db55245c2b3ca6bbe8.tar.gz
chromium_src-69c03be52ad42b06ff1d29db55245c2b3ca6bbe8.tar.bz2
Further tweaks to passphrase UI: change the text and spacing so that it fits better on windows. Add the reset UI to the "enter passphrase" screen so there is a solution if you can't remember the passphrase at that point. Also removing some code rendered unnecessary by my last change.
BUG=61027 TEST=none Review URL: http://codereview.chromium.org/6142010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70982 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/app/generated_resources.grd6
-rw-r--r--chrome/browser/sync/resources/configure.html5
-rw-r--r--chrome/browser/sync/resources/passphrase.html58
-rw-r--r--chrome/browser/sync/sync_setup_wizard.cc3
4 files changed, 23 insertions, 49 deletions
diff --git a/chrome/app/generated_resources.grd b/chrome/app/generated_resources.grd
index b14a851..7a561d6 100644
--- a/chrome/app/generated_resources.grd
+++ b/chrome/app/generated_resources.grd
@@ -8492,7 +8492,7 @@ Keep your key file in a safe place. You will need it to create new versions of y
Set up encrypted sync
</message>
<message name="IDS_SYNC_FIRST_PASSPHRASE_MESSAGE" desc="Message for setting up first passphrase.">
- To sync passwords, <ph name="PRODUCT_NAME">$1<ex>Chrome</ex></ph> requires you to encrypt your data using either your Google password or your own passphrase.
+ To sync passwords, <ph name="PRODUCT_NAME">$1<ex>Chrome</ex></ph> requires you to encrypt certain data using either your Google password or your own passphrase.
</message>
<message name="IDS_SYNC_PASSPHRASE_OPT_GOOGLE" desc="Radio button label for using Google password.">
Use my Google password.
@@ -8507,7 +8507,7 @@ Keep your key file in a safe place. You will need it to create new versions of y
You have chosen to encrypt data using your Google password; you can always change your mind later by changing your sync settings.
</message>
<message name="IDS_SYNC_PASSPHRASE_MSG_EXPLICIT" desc="Message when explicit passphrase is selected.">
- Only someone with your passphrase can read your data. Google does not store your passphrase. If you lose or forget your passphrase, you will have to reset sync.
+ Only someone with your passphrase can read your data. Google does not store your passphrase. If you forget your passphrase, you will need to reset sync.
</message>
<message name="IDS_SYNC_PASSPHRASE_MSG_CANCEL" desc="Message when not syncing passwords is selected.">
You have chosen not to sync passwords; you can always change your mind later by changing your sync settings.
@@ -8659,7 +8659,7 @@ Keep your key file in a safe place. You will need it to create new versions of y
Use a sync passphrase to encrypt my data
</message>
<message name="IDS_SYNC_PASSPHRASE_WARNING" desc="Warning message about using a passphrase for sync.">
- You are currently using a passphrase. If you've lost or forgotten your passphrase, you can reset sync to clear your synced data from Google's servers using the Google Privacy Dashboard.
+ You are currently using a passphrase. If you have forgotten your passphrase, you can reset sync to clear your synced data from Google's servers using the Google Privacy Dashboard.
</message>
<message name="IDS_SYNC_CLEAR_DATA_LINK" desc="Link to the Google Dashboard.">
Go to Google Privacy Dashboard
diff --git a/chrome/browser/sync/resources/configure.html b/chrome/browser/sync/resources/configure.html
index b087169..fb935cf 100644
--- a/chrome/browser/sync/resources/configure.html
+++ b/chrome/browser/sync/resources/configure.html
@@ -3,7 +3,7 @@
<title></title>
<style type="text/css">
body {
- line-height: 1.5em;
+ line-height: 1.33em;
background: #FFFFFF;
font-size: 11pt;
}
@@ -607,9 +607,6 @@ html[os='mac'] input[type='submit'] {
<div id="change-passphrase">
<div id="sync-passphrase-warning" i18n-content="passphraseWarning">
</div>
- <div id="sync-reset-confirmation" i18n-content="cleardataconfirmation"
- style="display: none;">
- </div>
<a id="clear-data-link" i18n-content="cleardatalink" href="#"
onclick='goToDashboard(); return false;'></a>
</div>
diff --git a/chrome/browser/sync/resources/passphrase.html b/chrome/browser/sync/resources/passphrase.html
index 4ea8317..55b633c 100644
--- a/chrome/browser/sync/resources/passphrase.html
+++ b/chrome/browser/sync/resources/passphrase.html
@@ -3,7 +3,7 @@
<title></title>
<style type="text/css">
body {
- line-height: 1.5em;
+ line-height: 1.4em;
background: #FFFFFF;
font-size: 11pt;
}
@@ -45,11 +45,10 @@ html[os='mac'] input[type='submit'] {
font-size: 12pt;
}
-#new-passphrase,
-#enter-passphrase {
- display: none;
+#passphrase-input {
+ margin-top: 5px;
+ margin-bottom: 50px;
}
-
</style>
<script src="chrome://resources/js/cr.js"></script>
<script>
@@ -63,27 +62,6 @@ html[os='mac'] input[type='submit'] {
} else if (!cr.isWindows) {
document.documentElement.setAttribute('os', 'linux');
}
-
- if (args) {
- currentMode = args['mode'];
- switchToMode(currentMode);
- }
- }
-
- function switchToMode(mode) {
- if (mode == "new") {
- document.getElementById("enter-passphrase").style.display = "none";
- document.getElementById("gaia-passphrase").style.display = "none";
- document.getElementById("new-passphrase").style.display = "block";
- } else if (mode =="enter") {
- document.getElementById("enter-passphrase").style.display = "block";
- document.getElementById("gaia-passphrase").style.display = "none";
- document.getElementById("new-passphrase").style.display = "none";
- } else if (mode == "gaia") {
- document.getElementById("enter-passphrase").style.display = "none";
- document.getElementById("gaia-passphrase").style.display = "block";
- document.getElementById("new-passphrase").style.display = "none";
- }
}
function sendPassphraseAndClose() {
@@ -92,19 +70,17 @@ html[os='mac'] input[type='submit'] {
"mode": currentMode});
chrome.send("Passphrase", [result]);
}
+
+ function goToDashboard() {
+ chrome.send("GoToDashboard", [""]);
+ chrome.send("DialogClose", [""]);
+ }
</script>
</head>
<body i18n-values=".style.fontFamily:fontfamily"
onload="setupPassphraseDialog();">
-<form id="passphraseForm"
+<form id="passphraseForm"
onSubmit="sendPassphraseAndClose(); return false;">
- <div id="new-passphrase">
- <div class="sync-header" id="newTitle"
- i18n-content="newPassphraseTitle"></div>
- <div class="sync-instructions" id="newInstructions"
- i18n-content="newPassphraseBody"></div>
- </div>
-
<div id="enter-passphrase">
<div class="sync-header" id="enterTitle"
i18n-content="enterPassphraseTitle"></div>
@@ -112,19 +88,17 @@ html[os='mac'] input[type='submit'] {
i18n-content="enterPassphraseBody"></div>
</div>
- <div id="gaia-passphrase">
- <div class="sync-header" id="gaiaTitle"
- i18n-content="gaiaPassphraseTitle"></div>
- <div class="sync-instructions" id="gaiaInstructions"
- i18n-content="gaiaPassphraseBody"></div>
- </div>
-
<div id="passphrase-input">
<label id="passphraseLabel" name="passphraseLabel"
for="passphrase" i18n-content="passphraseLabel">
</label>
<input id="passphrase" name="passphrase" type="password" />
- </div>
+ </div>
+
+ <div id="sync-passphrase-warning" i18n-content="passphraseWarning">
+ </div>
+ <a id="clear-data-link" i18n-content="cleardatalink" href="#"
+ onclick='goToDashboard(); return false;'></a>
<div class="sync-footer">
<input id="okButton" type="submit" i18n-values="value:ok" />
diff --git a/chrome/browser/sync/sync_setup_wizard.cc b/chrome/browser/sync/sync_setup_wizard.cc
index 6e9d254..5df5536 100644
--- a/chrome/browser/sync/sync_setup_wizard.cc
+++ b/chrome/browser/sync/sync_setup_wizard.cc
@@ -174,6 +174,9 @@ void SyncResourcesSource::StartDataRequest(const std::string& path_raw,
AddString(dict, "passphraseLabel", IDS_SYNC_PASSPHRASE_LABEL);
AddString(dict, "ok", IDS_OK);
AddString(dict, "cancel", IDS_CANCEL);
+
+ AddString(dict, "passphraseWarning", IDS_SYNC_PASSPHRASE_WARNING);
+ AddString(dict, "cleardatalink", IDS_SYNC_CLEAR_DATA_LINK);
} else if (path_raw == kSyncFirstPassphrasePath) {
html_resource_id = IDR_SYNC_FIRST_PASSPHRASE_HTML;
AddString(dict, "title", IDS_SYNC_FIRST_PASSPHRASE_TITLE);