Commit bad8d0b3 authored by Roman Sorokin's avatar Roman Sorokin Committed by Commit Bot

cros eula: Switch to loading screen before each load

Also removed obsolete 'eula-loading' class.

Fixed: 1068250
Change-Id: Ib7f1c08da113ba1af7934e12aee7434611f6e957
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2214528Reviewed-by: default avatarRenato Silva <rrsilva@google.com>
Commit-Queue: Roman Sorokin [CET] <rsorokin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#771564}
parent 2e1ed56d
......@@ -109,7 +109,8 @@ Polymer({
},
/**
* Event handler that is invoked when 'chrome://terms' is loaded.
* Event handler that is invoked when EULA is loaded. Either online version or
* 'chrome://terms' fallback.
*/
onFrameLoad_() {
this.acceptButtonDisabled = false;
......@@ -124,6 +125,7 @@ Polymer({
// This forces frame to reload.
const onlineEulaUrl = loadTimeData.getString('eulaOnlineUrl');
this.eulaLoadingScreenShown = true;
this.screen.loadEulaToWebview_(
this.$.crosEulaFrame, onlineEulaUrl, false /* clear_anchors */);
......
<div class="step right hidden animated eula-loading" id="eula" role="group"
<div class="step right hidden animated" id="eula" role="group"
i18n-values="aria-label:eulaScreenAccessibleTitle" hidden>
<oobe-eula-md id="oobe-eula-md"></oobe-eula-md>
</div>
......@@ -227,19 +227,12 @@ login.createScreen('EulaScreen', 'eula', function() {
chrome.send('EulaScreen.usageStatsEnabled', [value]);
},
/**
* Event handler that is invoked when 'chrome://terms' is loaded.
*/
onFrameLoad() {
$('eula').classList.remove('eula-loading');
},
/**
* Event handler that is invoked just before the screen is shown.
* @param {object} data Screen init payload.
*/
onBeforeShow() {
$('eula').classList.add('eula-loading');
$('oobe-eula-md').onBeforeShow();
this.updateLocalizedContent();
},
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment