Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(81)

Unified Diff: chrome/browser/resources/chromeos/login/screen_gaia_signin.js

Issue 1966853002: Add indication of camera use on SAML webcam logins (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/chromeos/login/screen_gaia_signin.js
diff --git a/chrome/browser/resources/chromeos/login/screen_gaia_signin.js b/chrome/browser/resources/chromeos/login/screen_gaia_signin.js
index 95006a488ee692fa416bb72c483a2abb91a6487d..e25a0a2dfd2dcf9e93d1e7a831b21c9eb70a7d58 100644
--- a/chrome/browser/resources/chromeos/login/screen_gaia_signin.js
+++ b/chrome/browser/resources/chromeos/login/screen_gaia_signin.js
@@ -215,6 +215,8 @@ login.createScreen('GaiaSigninScreen', 'gaia-signin', function() {
this.onAuthDomainChange_.bind(this));
this.gaiaAuthHost_.addEventListener('authFlowChange',
this.onAuthFlowChange_.bind(this));
+ this.gaiaAuthHost_.addEventListener('videoEnabledChange',
+ this.onVideoEnabledChange_.bind(this));
this.gaiaAuthHost_.addEventListener('loadAbort',
this.onLoadAbortMessage_.bind(this));
@@ -603,12 +605,34 @@ login.createScreen('GaiaSigninScreen', 'gaia-signin', function() {
},
/**
+ * Helper function to update the title bar.
+ */
+ updateSamlNotice_: function() {
+ if (this.gaiaAuthHost_.videoEnabled) {
+ $('saml-notice-message').textContent = loadTimeData.getStringF(
+ 'samlNoticeWithVideo',
+ this.gaiaAuthHost_.authDomain);
+ $('saml-notice-recording-indicator').hidden = false;
+ $('saml-notice-container').style.justifyContent = 'left';
Kevin Cernekee 2016/05/10 21:05:42 This part doesn't actually work. Not sure why. I
emaxx 2016/05/13 17:44:03 There is no "left" value among the allowed values
Kevin Cernekee 2016/05/13 18:39:04 Done.
+ } else {
+ $('saml-notice-message').textContent = loadTimeData.getStringF(
+ 'samlNotice',
+ this.gaiaAuthHost_.authDomain);
+ }
emaxx 2016/05/13 17:44:03 Even though the videoEnabled should never change f
Kevin Cernekee 2016/05/13 18:39:04 Done.
+ },
+
+ /**
* Invoked when the authDomain property is changed on the GAIA host.
*/
onAuthDomainChange_: function() {
- $('saml-notice-message').textContent = loadTimeData.getStringF(
- 'samlNotice',
- this.gaiaAuthHost_.authDomain);
+ this.updateSamlNotice_();
+ },
+
+ /**
+ * Invoked when the videoEnabled property is changed on the GAIA host.
+ */
+ onVideoEnabledChange_: function() {
+ this.updateSamlNotice_();
},
/**

Powered by Google App Engine
This is Rietveld 408576698