Commit cbfb93d0 authored by Mathias Carlen's avatar Mathias Carlen Committed by Commit Bot

[Autofill Assistant] Fix details margins.

Before this patch, the spacing between the details and the payment
request UI were too large.

This patch shows/hides the caroussel when the payment request is shown.
It's an intermediate quick fix before we have the new UI architecture
and works since the payment request is shown during a script execution,
which in turn again means that the caroussel is empty. Showing the
carousel reduces the margins of the details view.

R=jdemeulenaere@chromium.org, szermatt@google.com

Bug: 806868
Change-Id: I17d5d3bf138c8a2f68b24753fde55cada50984fa
Reviewed-on: https://chromium-review.googlesource.com/c/1341542
Commit-Queue: Mathias Carlen <mcarlen@chromium.org>
Reviewed-by: default avatarStephane Zermatten <szermatt@chromium.org>
Cr-Commit-Position: refs/heads/master@{#609723}
parent 53849705
......@@ -767,6 +767,9 @@ class AutofillAssistantUiDelegate {
webContents, paymentOptions, unusedTitle, supportedBasicCardNetworks);
// Make sure we wrap content in the container.
mBottomBarAnimations.setBottomBarHeightToWrapContent();
// Note: We show and hide (below) the carousel so that the margins are adjusted correctly.
// This is an intermediate adjustment before the UI refactoring.
mBottomBarAnimations.showCarousel();
mPaymentRequest.show(mCarouselScroll, callback);
enableProgressBarPulsing();
}
......@@ -776,6 +779,7 @@ class AutofillAssistantUiDelegate {
mPaymentRequest.close();
mPaymentRequest = null;
mBottomBarAnimations.setBottomBarHeightToFixed();
mBottomBarAnimations.hideCarousel();
disableProgressBarPulsing();
}
}
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