summaryrefslogtreecommitdiffstats
path: root/remoting/webapp/client_screen.js
diff options
context:
space:
mode:
authorjamiewalch@chromium.org <jamiewalch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-05-24 07:06:39 +0000
committerjamiewalch@chromium.org <jamiewalch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-05-24 07:06:39 +0000
commit4cc63fc8670f96870f69a6e1b42d28b8763fdaa7 (patch)
treefc1dd94ed6964281fea52cafc98f771aba7cd4c0 /remoting/webapp/client_screen.js
parentf20a99a23985538944aa5fafdc645fad9b578635 (diff)
downloadchromium_src-4cc63fc8670f96870f69a6e1b42d28b8763fdaa7.zip
chromium_src-4cc63fc8670f96870f69a6e1b42d28b8763fdaa7.tar.gz
chromium_src-4cc63fc8670f96870f69a6e1b42d28b8763fdaa7.tar.bz2
Show a 'remember me' checkbox in the web-app when connecting to a host that supports pairing.
Currently this checkbox does nothing. The next CL will add code to request pairing if it was checked. BUG=156182 Review URL: https://chromiumcodereview.appspot.com/15685008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@202001 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/webapp/client_screen.js')
-rw-r--r--remoting/webapp/client_screen.js12
1 files changed, 10 insertions, 2 deletions
diff --git a/remoting/webapp/client_screen.js b/remoting/webapp/client_screen.js
index ffd745c..feaf29d 100644
--- a/remoting/webapp/client_screen.js
+++ b/remoting/webapp/client_screen.js
@@ -265,8 +265,11 @@ remoting.connectMe2MeHostVersionAcknowledged_ = function(host) {
thirdPartyTokenFetcher.fetchToken();
};
- /** @param {function(string):void} onPinFetched */
- var requestPin = function(onPinFetched) {
+ /**
+ * @param {boolean} supportsPairing
+ * @param {function(string):void} onPinFetched
+ */
+ var requestPin = function(supportsPairing, onPinFetched) {
/** @type {Element} */
var pinForm = document.getElementById('pin-form');
/** @type {Element} */
@@ -296,6 +299,11 @@ remoting.connectMe2MeHostVersionAcknowledged_ = function(host) {
pinForm.addEventListener('submit', onSubmitOrCancel, false);
pinCancel.addEventListener('click', onSubmitOrCancel, false);
+ var rememberPin = document.getElementById('remember-pin');
+ rememberPin.hidden = !supportsPairing;
+ var checkbox = /** @type {HTMLInputElement} */
+ document.getElementById('remember-pin-checkbox');
+ checkbox.checked = false;
var message = document.getElementById('pin-message');
l10n.localizeElement(message, host.hostName);
remoting.setMode(remoting.AppMode.CLIENT_PIN_PROMPT);