| 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_state.h" | 5 #include "ash/wm/maximize_mode/maximize_mode_window_state.h" |
| 6 | 6 |
| 7 #include "ash/display/display_controller.h" | 7 #include "ash/display/display_controller.h" |
| 8 #include "ash/screen_util.h" | 8 #include "ash/screen_util.h" |
| 9 #include "ash/shell.h" | 9 #include "ash/shell.h" |
| 10 #include "ash/shell_window_ids.h" | 10 #include "ash/shell_window_ids.h" |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 125 break; | 125 break; |
| 126 case wm::WM_EVENT_TOGGLE_MAXIMIZE_CAPTION: | 126 case wm::WM_EVENT_TOGGLE_MAXIMIZE_CAPTION: |
| 127 case wm::WM_EVENT_TOGGLE_VERTICAL_MAXIMIZE: | 127 case wm::WM_EVENT_TOGGLE_VERTICAL_MAXIMIZE: |
| 128 case wm::WM_EVENT_TOGGLE_HORIZONTAL_MAXIMIZE: | 128 case wm::WM_EVENT_TOGGLE_HORIZONTAL_MAXIMIZE: |
| 129 case wm::WM_EVENT_TOGGLE_MAXIMIZE: | 129 case wm::WM_EVENT_TOGGLE_MAXIMIZE: |
| 130 case wm::WM_EVENT_CENTER: | 130 case wm::WM_EVENT_CENTER: |
| 131 case wm::WM_EVENT_SNAP_LEFT: | 131 case wm::WM_EVENT_SNAP_LEFT: |
| 132 case wm::WM_EVENT_SNAP_RIGHT: | 132 case wm::WM_EVENT_SNAP_RIGHT: |
| 133 case wm::WM_EVENT_NORMAL: | 133 case wm::WM_EVENT_NORMAL: |
| 134 case wm::WM_EVENT_MAXIMIZE: | 134 case wm::WM_EVENT_MAXIMIZE: |
| 135 case wm::WM_EVENT_DOCK: |
| 135 UpdateWindow(window_state, | 136 UpdateWindow(window_state, |
| 136 GetMaximizedOrCenteredWindowType(window_state), | 137 GetMaximizedOrCenteredWindowType(window_state), |
| 137 true); | 138 true); |
| 138 return; | 139 return; |
| 139 case wm::WM_EVENT_MINIMIZE: | 140 case wm::WM_EVENT_MINIMIZE: |
| 140 UpdateWindow(window_state, wm::WINDOW_STATE_TYPE_MINIMIZED, true); | 141 UpdateWindow(window_state, wm::WINDOW_STATE_TYPE_MINIMIZED, true); |
| 141 return; | 142 return; |
| 142 case wm::WM_EVENT_SHOW_INACTIVE: | 143 case wm::WM_EVENT_SHOW_INACTIVE: |
| 143 return; | 144 return; |
| 144 case wm::WM_EVENT_SET_BOUNDS: | 145 case wm::WM_EVENT_SET_BOUNDS: |
| (...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 294 // avoid flashing. | 295 // avoid flashing. |
| 295 if (window_state->IsMaximized()) | 296 if (window_state->IsMaximized()) |
| 296 window_state->SetBoundsDirectCrossFade(bounds_in_parent); | 297 window_state->SetBoundsDirectCrossFade(bounds_in_parent); |
| 297 else | 298 else |
| 298 window_state->SetBoundsDirectAnimated(bounds_in_parent); | 299 window_state->SetBoundsDirectAnimated(bounds_in_parent); |
| 299 } | 300 } |
| 300 } | 301 } |
| 301 } | 302 } |
| 302 | 303 |
| 303 } // namespace ash | 304 } // namespace ash |
| OLD | NEW |