Commit 25207aae authored by Fabian Sommer's avatar Fabian Sommer Committed by Commit Bot

Enable submitting SAML smart card dialog with Enter

Bug: 1027987
Change-Id: I5b4c779717217a40807475a48b74529752cb0f2d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1936292Reviewed-by: default avatarRoman Sorokin [CET] <rsorokin@chromium.org>
Commit-Queue: Fabian Sommer <fabiansommer@google.com>
Cr-Commit-Position: refs/heads/master@{#719546}
parent 2f7e078b
......@@ -30,7 +30,7 @@
has-error="[[hasError_(parameters, userEdited_)]]"
aria-label$="[[getAriaLabel_(locale, parameters, errorLabelId_,
userEdited_)]]"
on-pin-change="onPinChange_">
on-pin-change="onPinChange_" on-submit="onSubmit_">
<div id="errorContainer" problem
hidden="[[!hasError_(parameters, userEdited_)]]">
<iron-icon id="errorIcon" icon="cr:error-outline"></iron-icon>
......@@ -52,7 +52,7 @@
</div>
<div slot="bottom-buttons" class="layout horizontal justified">
<oobe-back-button on-tap="onBackClicked_"></oobe-back-button>
<oobe-next-button on-tap="onNextClicked_"
<oobe-next-button on-tap="onSubmit_"
disabled="[[processingCompletion_]]"></oobe-next-button>
</div>
</oobe-dialog>
......
......@@ -91,14 +91,14 @@ Polymer({
},
/**
* Invoked when the "Next" button is clicked.
* Invoked when the "Next" button is clicked or Enter is pressed.
* @private
*/
onNextClicked_: function() {
onSubmit_: function() {
if (this.processingCompletion_) {
// Race condition: This could happen if Polymer hasn't yet updated the
// "disabled" state of the "Next" button before the user clicked on it for
// the second time.
// Race condition: This could happen if the previous request has not yet
// been completed before the next one is sent (for example by pressing
// Enter twice)
return;
}
this.processingCompletion_ = true;
......
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