| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/ui/views/frame/immersive_mode_controller_ash.h" | 5 #include "chrome/browser/ui/views/frame/immersive_mode_controller_ash.h" |
| 6 | 6 |
| 7 #include "ash/common/material_design/material_design_controller.h" | 7 #include "ash/common/material_design/material_design_controller.h" |
| 8 #include "ash/common/wm/window_state.h" | 8 #include "ash/common/wm/window_state.h" |
| 9 #include "ash/shared/immersive_revealed_lock.h" | 9 #include "ash/shared/immersive_revealed_lock.h" |
| 10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| (...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 254 | 254 |
| 255 void ImmersiveModeControllerAsh::DestroyMashRevealWidget() { | 255 void ImmersiveModeControllerAsh::DestroyMashRevealWidget() { |
| 256 mash_reveal_widget_.reset(); | 256 mash_reveal_widget_.reset(); |
| 257 } | 257 } |
| 258 | 258 |
| 259 void ImmersiveModeControllerAsh::OnImmersiveRevealStarted() { | 259 void ImmersiveModeControllerAsh::OnImmersiveRevealStarted() { |
| 260 DestroyMashRevealWidget(); | 260 DestroyMashRevealWidget(); |
| 261 | 261 |
| 262 visible_fraction_ = 0; | 262 visible_fraction_ = 0; |
| 263 browser_view_->top_container()->SetPaintToLayer(); | 263 browser_view_->top_container()->SetPaintToLayer(); |
| 264 browser_view_->top_container()->layer()->SetFillsBoundsOpaquely(false); | |
| 265 UpdateTabIndicators(); | 264 UpdateTabIndicators(); |
| 266 LayoutBrowserRootView(); | 265 LayoutBrowserRootView(); |
| 267 CreateMashRevealWidget(); | 266 CreateMashRevealWidget(); |
| 268 for (Observer& observer : observers_) | 267 for (Observer& observer : observers_) |
| 269 observer.OnImmersiveRevealStarted(); | 268 observer.OnImmersiveRevealStarted(); |
| 270 } | 269 } |
| 271 | 270 |
| 272 void ImmersiveModeControllerAsh::OnImmersiveRevealEnded() { | 271 void ImmersiveModeControllerAsh::OnImmersiveRevealEnded() { |
| 273 DestroyMashRevealWidget(); | 272 DestroyMashRevealWidget(); |
| 274 visible_fraction_ = 0; | 273 visible_fraction_ = 0; |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 351 // the shelf completely and prevent it from being revealed. | 350 // the shelf completely and prevent it from being revealed. |
| 352 bool in_tab_fullscreen = content::Source<FullscreenController>(source)-> | 351 bool in_tab_fullscreen = content::Source<FullscreenController>(source)-> |
| 353 IsWindowFullscreenForTabOrPending(); | 352 IsWindowFullscreenForTabOrPending(); |
| 354 ash::wm::GetWindowState(native_window_) | 353 ash::wm::GetWindowState(native_window_) |
| 355 ->set_hide_shelf_when_fullscreen(in_tab_fullscreen); | 354 ->set_hide_shelf_when_fullscreen(in_tab_fullscreen); |
| 356 ash::Shell::GetInstance()->UpdateShelfVisibility(); | 355 ash::Shell::GetInstance()->UpdateShelfVisibility(); |
| 357 | 356 |
| 358 if (tab_indicator_visibility_changed) | 357 if (tab_indicator_visibility_changed) |
| 359 LayoutBrowserRootView(); | 358 LayoutBrowserRootView(); |
| 360 } | 359 } |
| OLD | NEW |