| 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: |
| 136 case wm::WM_EVENT_UNDOCK: |
| 135 UpdateWindow(window_state, | 137 UpdateWindow(window_state, |
| 136 GetMaximizedOrCenteredWindowType(window_state), | 138 GetMaximizedOrCenteredWindowType(window_state), |
| 137 true); | 139 true); |
| 138 return; | 140 return; |
| 139 case wm::WM_EVENT_MINIMIZE: | 141 case wm::WM_EVENT_MINIMIZE: |
| 140 UpdateWindow(window_state, wm::WINDOW_STATE_TYPE_MINIMIZED, true); | 142 UpdateWindow(window_state, wm::WINDOW_STATE_TYPE_MINIMIZED, true); |
| 141 return; | 143 return; |
| 142 case wm::WM_EVENT_SHOW_INACTIVE: | 144 case wm::WM_EVENT_SHOW_INACTIVE: |
| 143 return; | 145 return; |
| 144 case wm::WM_EVENT_SET_BOUNDS: | 146 case wm::WM_EVENT_SET_BOUNDS: |
| (...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 294 // avoid flashing. | 296 // avoid flashing. |
| 295 if (window_state->IsMaximized()) | 297 if (window_state->IsMaximized()) |
| 296 window_state->SetBoundsDirectCrossFade(bounds_in_parent); | 298 window_state->SetBoundsDirectCrossFade(bounds_in_parent); |
| 297 else | 299 else |
| 298 window_state->SetBoundsDirectAnimated(bounds_in_parent); | 300 window_state->SetBoundsDirectAnimated(bounds_in_parent); |
| 299 } | 301 } |
| 300 } | 302 } |
| 301 } | 303 } |
| 302 | 304 |
| 303 } // namespace ash | 305 } // namespace ash |
| OLD | NEW |