| 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/immersive_revealed_lock.h" | 8 #include "ash/common/wm/immersive_revealed_lock.h" |
| 9 #include "ash/common/wm/window_state.h" | 9 #include "ash/common/wm/window_state.h" |
| 10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| (...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 259 return; | 259 return; |
| 260 | 260 |
| 261 bool tab_indicator_visibility_changed = UpdateTabIndicators(); | 261 bool tab_indicator_visibility_changed = UpdateTabIndicators(); |
| 262 | 262 |
| 263 // Auto hide the shelf in immersive browser fullscreen. When auto hidden and | 263 // Auto hide the shelf in immersive browser fullscreen. When auto hidden and |
| 264 // Material Design is not enabled, the shelf displays a 3px 'light bar' when | 264 // Material Design is not enabled, the shelf displays a 3px 'light bar' when |
| 265 // it is closed. When in immersive browser fullscreen and tab fullscreen, hide | 265 // it is closed. When in immersive browser fullscreen and tab fullscreen, hide |
| 266 // the shelf completely and prevent it from being revealed. | 266 // the shelf completely and prevent it from being revealed. |
| 267 bool in_tab_fullscreen = content::Source<FullscreenController>(source)-> | 267 bool in_tab_fullscreen = content::Source<FullscreenController>(source)-> |
| 268 IsWindowFullscreenForTabOrPending(); | 268 IsWindowFullscreenForTabOrPending(); |
| 269 ash::wm::GetWindowState(native_window_)->set_hide_shelf_when_fullscreen( | 269 ash::wm::GetWindowState(native_window_) |
| 270 in_tab_fullscreen); | 270 ->set_shelf_mode_in_fullscreen( |
| 271 in_tab_fullscreen ? ash::wm::WindowState::SHELF_HIDDEN |
| 272 : ash::wm::WindowState::SHELF_AUTO_HIDE_VISIBLE); |
| 271 ash::Shell::GetInstance()->UpdateShelfVisibility(); | 273 ash::Shell::GetInstance()->UpdateShelfVisibility(); |
| 272 | 274 |
| 273 if (tab_indicator_visibility_changed) | 275 if (tab_indicator_visibility_changed) |
| 274 LayoutBrowserRootView(); | 276 LayoutBrowserRootView(); |
| 275 } | 277 } |
| OLD | NEW |