summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--remoting/webapp/_locales/en/messages.json4
-rw-r--r--remoting/webapp/host_setup_dialog.js18
-rw-r--r--remoting/webapp/main.html3
3 files changed, 20 insertions, 5 deletions
diff --git a/remoting/webapp/_locales/en/messages.json b/remoting/webapp/_locales/en/messages.json
index b235aaf..da65ca5 100644
--- a/remoting/webapp/_locales/en/messages.json
+++ b/remoting/webapp/_locales/en/messages.json
@@ -246,6 +246,10 @@
"message": "Remote connections for this computer have been enabled.",
"description": "Message shown after access to local computer has been enabled successfully."
},
+ "HOST_SETUP_STARTED_DISABLE_SLEEP": {
+ "message": "Please check your computer's power management settings and ensure that it is not configured to sleep when idle.",
+ "description": "Instructions to the user to ask them to disable power management for the computer in order to be able to connect to it."
+ },
"HOST_SETUP_STARTING": {
"message": "enabling remote connections for this computer\u2026",
"description": "Message shown when local machine is being registered in the directory and when starting the host."
diff --git a/remoting/webapp/host_setup_dialog.js b/remoting/webapp/host_setup_dialog.js
index 8bee4661..01c4947 100644
--- a/remoting/webapp/host_setup_dialog.js
+++ b/remoting/webapp/host_setup_dialog.js
@@ -219,10 +219,17 @@ remoting.HostSetupDialog.prototype.updateState_ = function() {
l10n.localizeElementFromTag(messageDiv, tag);
remoting.setMode(remoting.AppMode.HOST_SETUP_PROCESSING);
}
- /** @param {string} tag */
- function showDoneMessage(tag) {
+ /** @param {string} tag1
+ * @param {string=} opt_tag2 */
+ function showDoneMessage(tag1, opt_tag2) {
var messageDiv = document.getElementById('host-setup-done-message');
- l10n.localizeElementFromTag(messageDiv, tag);
+ l10n.localizeElementFromTag(messageDiv, tag1);
+ messageDiv = document.getElementById('host-setup-done-message-2');
+ if (opt_tag2) {
+ l10n.localizeElementFromTag(messageDiv, opt_tag2);
+ } else {
+ messageDiv.innerHTML = '';
+ }
remoting.setMode(remoting.AppMode.HOST_SETUP_DONE);
}
/** @param {string} tag */
@@ -251,7 +258,10 @@ remoting.HostSetupDialog.prototype.updateState_ = function() {
showProcessingMessage(/*i18n-content*/'HOST_SETUP_STOPPING');
this.stopHost_();
} else if (state == remoting.HostSetupFlow.State.HOST_STARTED) {
- showDoneMessage(/*i18n-content*/'HOST_SETUP_STARTED');
+ // TODO(jamiewalch): Only display the second string if the computer's power
+ // management settings indicate that it's necessary.
+ showDoneMessage(/*i18n-content*/'HOST_SETUP_STARTED',
+ /*i18n-content*/'HOST_SETUP_STARTED_DISABLE_SLEEP');
} else if (state == remoting.HostSetupFlow.State.UPDATED_PIN) {
showDoneMessage(/*i18n-content*/'HOST_SETUP_UPDATED_PIN');
} else if (state == remoting.HostSetupFlow.State.HOST_STOPPED) {
diff --git a/remoting/webapp/main.html b/remoting/webapp/main.html
index 81523c4..c7c7d56 100644
--- a/remoting/webapp/main.html
+++ b/remoting/webapp/main.html
@@ -234,7 +234,8 @@ found in the LICENSE file.
</div>
<div data-ui-mode="home.host-setup.done" hidden>
<div id="host-setup-done-message" class="message"></div>
- <div class="button-row">
+ <div id="host-setup-done-message-2" class="message"></div>
+ <div class="button-row">
<div class="box-spacer"></div>
<button id="host-config-done-dismiss" i18n-content="OK"></button>
</div>