OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "ash/wm/maximize_mode/maximize_mode_window_manager.h" | 5 #include "ash/wm/maximize_mode/maximize_mode_window_manager.h" |
6 | 6 |
7 #include "ash/root_window_controller.h" | 7 #include "ash/root_window_controller.h" |
8 #include "ash/shell.h" | 8 #include "ash/shell.h" |
9 #include "ash/shell_window_ids.h" | 9 #include "ash/shell_window_ids.h" |
10 #include "ash/wm/maximize_mode/maximize_mode_window_state.h" | 10 #include "ash/wm/maximize_mode/maximize_mode_window_state.h" |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 void MaximizeModeWindowManager::OnWindowBoundsChanged( | 123 void MaximizeModeWindowManager::OnWindowBoundsChanged( |
124 aura::Window* window, | 124 aura::Window* window, |
125 const gfx::Rect& old_bounds, | 125 const gfx::Rect& old_bounds, |
126 const gfx::Rect& new_bounds) { | 126 const gfx::Rect& new_bounds) { |
127 if (!IsContainerWindow(window)) | 127 if (!IsContainerWindow(window)) |
128 return; | 128 return; |
129 // Reposition all non maximizeable windows. | 129 // Reposition all non maximizeable windows. |
130 for (WindowToState::iterator it = window_state_map_.begin(); | 130 for (WindowToState::iterator it = window_state_map_.begin(); |
131 it != window_state_map_.end(); | 131 it != window_state_map_.end(); |
132 ++it) { | 132 ++it) { |
133 it->second->UpdateWindowPosition(wm::GetWindowState(it->first), false); | 133 it->second->UpdateWindowPosition(wm::GetWindowState(it->first)); |
134 } | 134 } |
135 } | 135 } |
136 | 136 |
137 void MaximizeModeWindowManager::OnDisplayAdded(const gfx::Display& display) { | 137 void MaximizeModeWindowManager::OnDisplayAdded(const gfx::Display& display) { |
138 DisplayConfigurationChanged(); | 138 DisplayConfigurationChanged(); |
139 } | 139 } |
140 | 140 |
141 void MaximizeModeWindowManager::OnDisplayRemoved(const gfx::Display& display) { | 141 void MaximizeModeWindowManager::OnDisplayRemoved(const gfx::Display& display) { |
142 DisplayConfigurationChanged(); | 142 DisplayConfigurationChanged(); |
143 } | 143 } |
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
294 RootWindowController* controller = *iter; | 294 RootWindowController* controller = *iter; |
295 aura::Window* container = Shell::GetContainer( | 295 aura::Window* container = Shell::GetContainer( |
296 controller->GetRootWindow(), kShellWindowId_DefaultContainer); | 296 controller->GetRootWindow(), kShellWindowId_DefaultContainer); |
297 controller->workspace_controller()->SetMaximizeBackdropDelegate( | 297 controller->workspace_controller()->SetMaximizeBackdropDelegate( |
298 scoped_ptr<WorkspaceLayoutManagerDelegate>( | 298 scoped_ptr<WorkspaceLayoutManagerDelegate>( |
299 enable ? new WorkspaceBackdropDelegate(container) : NULL)); | 299 enable ? new WorkspaceBackdropDelegate(container) : NULL)); |
300 } | 300 } |
301 } | 301 } |
302 | 302 |
303 } // namespace ash | 303 } // namespace ash |
OLD | NEW |