Commit 8f075b26 authored by Toni Barzic's avatar Toni Barzic Committed by Commit Bot

shelf: Do not blur animating background

The animating background is shown during hotseat animation, and might
cause double blur (for example, navigation control, or hotseat blur
might be active at the same time).

BUG=1034045

Change-Id: I9ef8e06cdcd2b9662ba91eb4728ac4f1cef4f19a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1986328Reviewed-by: default avatarAlex Newcomer <newcomer@chromium.org>
Reviewed-by: default avatarManu Cornet <manucornet@chromium.org>
Commit-Queue: Toni Baržić <tbarzic@chromium.org>
Cr-Commit-Position: refs/heads/master@{#728121}
parent 120630de
...@@ -189,11 +189,8 @@ ShelfWidget::DelegateView::DelegateView(ShelfWidget* shelf_widget) ...@@ -189,11 +189,8 @@ ShelfWidget::DelegateView::DelegateView(ShelfWidget* shelf_widget)
// |animating_background_| will be made visible during hotseat animations. // |animating_background_| will be made visible during hotseat animations.
ShowAnimatingBackground(false); ShowAnimatingBackground(false);
if (features::IsBackgroundBlurEnabled()) { animating_background_.SetColor(ShelfConfig::Get()->GetMaximizedShelfColor());
animating_background_.SetBackdropFilterQuality(0.33f);
animating_background_.SetColor(
ShelfConfig::Get()->GetMaximizedShelfColor());
}
std::unique_ptr<views::View> drag_handle_ptr = std::unique_ptr<views::View> drag_handle_ptr =
std::make_unique<views::View>(); std::make_unique<views::View>();
const int radius = kDragHandleCornerRadius; const int radius = kDragHandleCornerRadius;
...@@ -406,11 +403,6 @@ void ShelfWidget::DelegateView::OnHotseatTransitionAnimationEnded( ...@@ -406,11 +403,6 @@ void ShelfWidget::DelegateView::OnHotseatTransitionAnimationEnded(
void ShelfWidget::DelegateView::ShowAnimatingBackground(bool show) { void ShelfWidget::DelegateView::ShowAnimatingBackground(bool show) {
animating_background_.SetVisible(show); animating_background_.SetVisible(show);
// To ensure smooth scrollable shelf animations, we disable blur when the
// |animating_background_| is not visible.
if (features::IsBackgroundBlurEnabled())
animating_background_.SetBackgroundBlur(show ? 30 : 0);
} }
SkColor ShelfWidget::DelegateView::GetShelfBackgroundColor() const { SkColor ShelfWidget::DelegateView::GetShelfBackgroundColor() const {
......
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