From f46f86c6c0b32fdc98b7c27ace907de67d735fe8 Mon Sep 17 00:00:00 2001 From: dzhioev Date: Mon, 11 May 2015 23:09:22 -0700 Subject: [PATCH] Refresh button for FrE and recovery modes added to enrollment screen. In addition fixed an issue where <- button was shown when it should not. BUG=472671 TEST=manually,tested FrE and recovery modes, button works as expected. Review URL: https://codereview.chromium.org/1132043002 Cr-Commit-Position: refs/heads/master@{#329361} --- .../login/oobe_screen_oauth_enrollment_webview.css | 34 +++++++++++++++++----- .../oobe_screen_oauth_enrollment_webview.html | 3 ++ .../login/oobe_screen_oauth_enrollment_webview.js | 2 ++ 3 files changed, 31 insertions(+), 8 deletions(-) diff --git a/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.css b/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.css index 02733dd517a9..a0d6c553460b 100644 --- a/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.css +++ b/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.css @@ -79,13 +79,23 @@ display: none; } +#oauth-enroll-back-button, +#oauth-enrollment.saml #oauth-enroll-back-button { + display: none; +} + +.oauth-enroll-state-signin #oauth-enroll-back-button { + display: inline; +} + .oauth-enroll-state-signin.mode-manual #oauth-enroll-cancel-button, -.oauth-enroll-state-signin #oauth-enroll-back-button, +.oauth-enroll-state-signin.mode-forced #oauth-enroll-refresh-button, +.oauth-enroll-state-signin.mode-recovery #oauth-enroll-refresh-button, .oauth-enroll-state-working.mode-manual #oauth-enroll-cancel-button, -.oauth-enroll-state-working #oauth-enroll-back-button, +.oauth-enroll-state-working.mode-forced #oauth-enroll-refresh-button, +.oauth-enroll-stain-working.mode-recovery #oauth-enroll-refresh-button, .oauth-enroll-state-error.mode-manual #oauth-enroll-cancel-button, .oauth-enroll-state-error.mode-manual #oauth-enroll-done-button, -.oauth-enroll-state-error #oauth-enroll-back-button, .oauth-enroll-state-success #oauth-enroll-done-button { display: inline; } @@ -123,27 +133,34 @@ } #oauth-enroll-cancel-button, -#oauth-enroll-back-button { +#oauth-enroll-back-button, +#oauth-enroll-refresh-button { position: absolute; top: 10px; + z-index: 1; } -#oauth-enroll-cancel-button { +#oauth-enroll-cancel-button, +#oauth-enroll-refresh-button { color: rgba(0, 0, 0, .54); right: 10px; } -html[dir=rtl] #oauth-enroll-cancel-button { +html[dir=rtl] #oauth-enroll-cancel-button, +html[dir=rtl] #oauth-enroll-refresh-button { left: 10px; right: auto; } -#oauth-enrollment.saml #oauth-enroll-cancel-button { +#oauth-enrollment.saml #oauth-enroll-cancel-button, +#oauth-enrollment.saml #oauth-enroll-refresh-button { color: rgba(0, 0, 0, .54); } .oauth-enroll-state-signin #oauth-enroll-cancel-button, -.oauth-enroll-state-working #oauth-enroll-cancel-button { +.oauth-enroll-state-working #oauth-enroll-cancel-button, +.oauth-enroll-state-signin #oauth-enroll-refresh-button, +.oauth-enroll-state-working #oauth-enroll-refresh-button { color: white; } @@ -165,3 +182,4 @@ html[dir=rtl] #oauth-enroll-back-button { #oauth-enroll-attribute-prompt-message { color: black; } + diff --git a/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.html b/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.html index 8006dfd16db1..c2c8a6161b12 100644 --- a/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.html +++ b/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.html @@ -68,4 +68,7 @@ + diff --git a/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.js b/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.js index 6ff8f3a18ed3..4cd8fe50fb8a 100644 --- a/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.js +++ b/chrome/browser/resources/chromeos/login/oobe_screen_oauth_enrollment_webview.js @@ -120,6 +120,8 @@ login.createScreen('OAuthEnrollmentScreen', 'oauth-enrollment', function() { $('oauth-enroll-cancel-button').addEventListener('click', this.cancel.bind(this)); + $('oauth-enroll-refresh-button').addEventListener('click', + this.cancel.bind(this)); $('oauth-enroll-back-button').addEventListener('click', (function(e) { -- 2.11.4.GIT