Commit 59a45f26 authored by Stephane Zermatten's avatar Stephane Zermatten Committed by Commit Bot

[Autofill Assistant] Don't add a cancel button when onboarding.

Before this patch, there could be a cancel button on the onboarding
screen. With this patch, the button is gone.

With the latest refactorings, UiControllerAndroid::UpdateActions() can
now be called while in the inactive state, when showing onboarding. It
needs to handle that state as well.

Change-Id: I5b955ac8e7b854bb6a17798837f1ab1a6ea9e4d1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1541777Reviewed-by: default avatarJordan Demeulenaere <jdemeulenaere@chromium.org>
Commit-Queue: Jordan Demeulenaere <jdemeulenaere@chromium.org>
Cr-Commit-Position: refs/heads/master@{#644838}
parent d42551b8
......@@ -407,7 +407,7 @@ void UiControllerAndroid::UpdateActions() {
env, java_object_, chips,
base::android::ConvertUTF8ToJavaString(
env, l10n_util::GetStringUTF8(IDS_CLOSE)));
} else {
} else if (ui_delegate_->GetState() != AutofillAssistantState::INACTIVE) {
Java_AutofillAssistantUiController_addCancelButton(
env, java_object_, chips,
base::android::ConvertUTF8ToJavaString(
......
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