Commit b131a32a authored by Denis Kuznetsov's avatar Denis Kuznetsov Committed by Commit Bot

OOBE: Fix default focus for Enterprise enrollment screen

Focusing element marked as "focus-on-show" is done by oobe-dialog's
show() method. MultiStepBehavior triggers this method for elements
marked as for-step, but enrollment_screen used legacy layout where
each oobe-dialog was additionally wrapped in the <div>, and for-step
was set on the enclosing div instead of oobe-dialog.
As a result, show() was not called on corresponding oobe-dialog upon
step switch, and default focus was not set

Bug: 1021608
Change-Id: I5d103f735ff5155a190c0a74c7d215fe293a2c83
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2414189Reviewed-by: default avatarRoman Sorokin [CET] <rsorokin@chromium.org>
Commit-Queue: Denis Kuznetsov [CET] <antrim@chromium.org>
Cr-Commit-Position: refs/heads/master@{#807869}
parent 4285cf4c
......@@ -41,8 +41,7 @@
</div>
<!-- ENROLLMENT IN PROGRESS (SPINNER) DIALOG -->
<div id="step-working" for-step="working">
<oobe-dialog id="working"
<oobe-dialog id="step-working" for-step="working"
title-key="oauthEnrollScreenTitle">
<hd-iron-icon slot="oobe-icon"
icon1x="oobe-32:enterprise" icon2x="oobe-64:enterprise">
......@@ -55,7 +54,6 @@
</div>
</div>
</oobe-dialog>
</div>
<div id="step-ad-join" for-step="ad-join">
<offline-ad-login id="adJoinUI" is-domain-join
class="fit"
......@@ -74,9 +72,8 @@
AttributePrompt: [ 'Done' ]
ActiveDirectoryJoin: [ 'Try Again' ]
-->
<div id="step-error" role="alert"
<oobe-dialog id="step-error" has-buttons role="alert"
for-step="error, attribute-prompt-error, active-directory-join-error">
<oobe-dialog id="errorCard" has-buttons>
<hd-iron-icon slot="oobe-icon"
icon1x="oobe-32:enterprise"
icon2x="oobe-64:enterprise"></hd-iron-icon>
......@@ -133,11 +130,9 @@
</div>
</oobe-dialog>
</div>
<!-- SUCCESS DIALOG -->
<div id="step-success" for-step="success" role="alert">
<oobe-dialog id="successCard" has-buttons
<oobe-dialog has-buttons id="step-success" for-step="success" role="alert"
title-key="oauthEnrollSuccessTitle" footer-shrinkable>
<hd-iron-icon slot="oobe-icon"
icon1x="oobe-32:enterprise" icon2x="oobe-64:enterprise">
......@@ -160,12 +155,10 @@
class="focus-on-show"></oobe-text-button>
</div>
</oobe-dialog>
</div>
<!-- ATTRIBUTE PROMPT DIALOG -->
<div id="step-attribute-prompt" for-step="attribute-prompt">
<oobe-dialog id="attributePromptCard" has-buttons
title-key="oauthEnrollScreenTitle"
<oobe-dialog id="step-attribute-prompt" for-step="attribute-prompt"
has-buttons title-key="oauthEnrollScreenTitle"
subtitle-key="oauthEnrollDeviceInformation">
<hd-iron-icon slot="oobe-icon"
icon1x="oobe-32:enterprise" icon2x="oobe-64:enterprise">
......@@ -200,7 +193,6 @@
</div>
</oobe-dialog>
</div>
</div>
<div class="popup-overlay"
hidden="[[!showPopupOverlay_(authenticatorDialogDisplayed_,
isSamlSsoVisible_)]]">
......
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