| Index: components/exo/shell_surface.cc
|
| diff --git a/components/exo/shell_surface.cc b/components/exo/shell_surface.cc
|
| index da62c7779a4c368ccc8d44496f9e886dbb619026..6248a27c13212c96588327d4db216d9844e79d12 100644
|
| --- a/components/exo/shell_surface.cc
|
| +++ b/components/exo/shell_surface.cc
|
| @@ -1253,6 +1253,7 @@ void ShellSurface::UpdateShadow() {
|
| window->StackChildAtBottom(shadow_underlay_);
|
| }
|
|
|
| + float shadow_underlay_opacity = rectangular_shadow_background_opacity_;
|
| // Put the black background layer behind the window if
|
| // 1) the window is in immersive fullscreen.
|
| // 2) the window can control the bounds of the window in fullscreen (
|
| @@ -1264,14 +1265,20 @@ void ShellSurface::UpdateShadow() {
|
| window->layer()->transform().IsIdentity()) {
|
| gfx::Point origin;
|
| origin -= window->bounds().origin().OffsetFromOrigin();
|
| - gfx::Rect background_bounds(origin, window->parent()->bounds().size());
|
| - shadow_underlay_->SetBounds(background_bounds);
|
| - shadow_underlay_->layer()->SetOpacity(1.f);
|
| - } else {
|
| - shadow_underlay_->SetBounds(shadow_bounds);
|
| - shadow_underlay_->layer()->SetOpacity(
|
| - rectangular_shadow_background_opacity_);
|
| + shadow_bounds.set_origin(origin);
|
| + shadow_bounds.set_size(window->parent()->bounds().size());
|
| + shadow_underlay_opacity = 1.0f;
|
| }
|
| +
|
| + shadow_underlay_->SetBounds(shadow_bounds);
|
| +
|
| + // TODO(oshima): Setting to the same value should be no-op.
|
| + // crbug.com/642223.
|
| + if (shadow_underlay_opacity !=
|
| + shadow_underlay_->layer()->GetTargetOpacity()) {
|
| + shadow_underlay_->layer()->SetOpacity(shadow_underlay_opacity);
|
| + }
|
| +
|
| shadow_underlay_->Show();
|
|
|
| wm::Shadow* shadow = wm::ShadowController::GetShadowForWindow(window);
|
|
|