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 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
268 for (Observer& observer : observers_) | 268 for (Observer& observer : observers_) |
269 observer.OnImmersiveRevealStarted(); | 269 observer.OnImmersiveRevealStarted(); |
270 } | 270 } |
271 | 271 |
272 void ImmersiveModeControllerAsh::OnImmersiveRevealEnded() { | 272 void ImmersiveModeControllerAsh::OnImmersiveRevealEnded() { |
273 DestroyMashRevealWidget(); | 273 DestroyMashRevealWidget(); |
274 visible_fraction_ = 0; | 274 visible_fraction_ = 0; |
275 browser_view_->top_container()->DestroyLayer(); | 275 browser_view_->top_container()->DestroyLayer(); |
276 UpdateTabIndicators(); | 276 UpdateTabIndicators(); |
277 LayoutBrowserRootView(); | 277 LayoutBrowserRootView(); |
| 278 for (Observer& observer : observers_) |
| 279 observer.OnImmersiveRevealEnded(); |
278 } | 280 } |
279 | 281 |
280 void ImmersiveModeControllerAsh::OnImmersiveFullscreenExited() { | 282 void ImmersiveModeControllerAsh::OnImmersiveFullscreenExited() { |
281 DestroyMashRevealWidget(); | 283 DestroyMashRevealWidget(); |
282 browser_view_->top_container()->DestroyLayer(); | 284 browser_view_->top_container()->DestroyLayer(); |
283 UpdateTabIndicators(); | 285 UpdateTabIndicators(); |
284 LayoutBrowserRootView(); | 286 LayoutBrowserRootView(); |
285 } | 287 } |
286 | 288 |
287 void ImmersiveModeControllerAsh::SetVisibleFraction(double visible_fraction) { | 289 void ImmersiveModeControllerAsh::SetVisibleFraction(double visible_fraction) { |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
351 // the shelf completely and prevent it from being revealed. | 353 // the shelf completely and prevent it from being revealed. |
352 bool in_tab_fullscreen = content::Source<FullscreenController>(source)-> | 354 bool in_tab_fullscreen = content::Source<FullscreenController>(source)-> |
353 IsWindowFullscreenForTabOrPending(); | 355 IsWindowFullscreenForTabOrPending(); |
354 ash::wm::GetWindowState(native_window_) | 356 ash::wm::GetWindowState(native_window_) |
355 ->set_hide_shelf_when_fullscreen(in_tab_fullscreen); | 357 ->set_hide_shelf_when_fullscreen(in_tab_fullscreen); |
356 ash::Shell::GetInstance()->UpdateShelfVisibility(); | 358 ash::Shell::GetInstance()->UpdateShelfVisibility(); |
357 | 359 |
358 if (tab_indicator_visibility_changed) | 360 if (tab_indicator_visibility_changed) |
359 LayoutBrowserRootView(); | 361 LayoutBrowserRootView(); |
360 } | 362 } |
OLD | NEW |