Commit 1db9d20f authored by Mitsuru Oshima's avatar Mitsuru Oshima Committed by Commit Bot

Don't use blur when maximized

Also use NOT_DRAWN layer for shelf because it has no real content.
All child views have its own layers.

This also chagnes the opacity to 100% per discussion with sgabriel@

Bug: 899079
Test: manual. No
Change-Id: I6ea82784e49e929902a7a7d00fc934d9c8033045
Reviewed-on: https://chromium-review.googlesource.com/c/1300108Reviewed-by: default avatarSammie Quon <sammiequon@chromium.org>
Commit-Queue: Mitsuru Oshima <oshima@chromium.org>
Cr-Commit-Position: refs/heads/master@{#602942}
parent 77cbc4f0
...@@ -69,7 +69,7 @@ ASH_EXPORT constexpr SkColor kShelfIconColor = SK_ColorWHITE; ...@@ -69,7 +69,7 @@ ASH_EXPORT constexpr SkColor kShelfIconColor = SK_ColorWHITE;
// The alpha value for the shelf background. // The alpha value for the shelf background.
ASH_EXPORT constexpr int kShelfTranslucentOverAppList = 51; // 20% ASH_EXPORT constexpr int kShelfTranslucentOverAppList = 51; // 20%
ASH_EXPORT constexpr int kShelfTranslucentAlpha = 153; // 60% ASH_EXPORT constexpr int kShelfTranslucentAlpha = 153; // 60%
ASH_EXPORT constexpr int kShelfTranslucentMaximizedWindow = 230; // 90% ASH_EXPORT constexpr int kShelfTranslucentMaximizedWindow = 255; // 100%
// The alpha value used to darken a colorized shelf when the shelf is // The alpha value used to darken a colorized shelf when the shelf is
// translucent. // translucent.
......
...@@ -1173,9 +1173,10 @@ bool ShelfLayoutManager::IsShelfAutoHideForFullscreenMaximized() const { ...@@ -1173,9 +1173,10 @@ bool ShelfLayoutManager::IsShelfAutoHideForFullscreenMaximized() const {
} }
bool ShelfLayoutManager::ShouldBlurShelfBackground() { bool ShelfLayoutManager::ShouldBlurShelfBackground() {
if (!IsBackgroundBlurEnabled()) return IsBackgroundBlurEnabled() &&
return false; (shelf_background_type_ == SHELF_BACKGROUND_DEFAULT ||
return state_.session_state == session_manager::SessionState::ACTIVE; shelf_background_type_ == SHELF_BACKGROUND_OVERLAP) &&
state_.session_state == session_manager::SessionState::ACTIVE;
} }
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
......
...@@ -289,7 +289,7 @@ ShelfWidget::ShelfWidget(aura::Window* shelf_container, Shelf* shelf) ...@@ -289,7 +289,7 @@ ShelfWidget::ShelfWidget(aura::Window* shelf_container, Shelf* shelf)
views::Widget::InitParams params( views::Widget::InitParams params(
views::Widget::InitParams::TYPE_WINDOW_FRAMELESS); views::Widget::InitParams::TYPE_WINDOW_FRAMELESS);
params.name = "ShelfWidget"; params.name = "ShelfWidget";
params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; params.layer_type = ui::LAYER_NOT_DRAWN;
params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET;
params.delegate = delegate_view_; params.delegate = delegate_view_;
params.parent = shelf_container; params.parent = shelf_container;
......
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