| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 <algorithm> | 5 #include <algorithm> |
| 6 #include <vector> | 6 #include <vector> |
| 7 | 7 |
| 8 #include "ash/common/accessibility_delegate.h" | 8 #include "ash/common/accessibility_delegate.h" |
| 9 #include "ash/common/accessibility_types.h" | 9 #include "ash/common/accessibility_types.h" |
| 10 #include "ash/common/shelf/wm_shelf.h" | 10 #include "ash/common/shelf/wm_shelf.h" |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 return window; | 152 return window; |
| 153 } | 153 } |
| 154 | 154 |
| 155 bool WindowsOverlapping(aura::Window* window1, aura::Window* window2) { | 155 bool WindowsOverlapping(aura::Window* window1, aura::Window* window2) { |
| 156 gfx::Rect window1_bounds = GetTransformedTargetBounds(window1); | 156 gfx::Rect window1_bounds = GetTransformedTargetBounds(window1); |
| 157 gfx::Rect window2_bounds = GetTransformedTargetBounds(window2); | 157 gfx::Rect window2_bounds = GetTransformedTargetBounds(window2); |
| 158 return window1_bounds.Intersects(window2_bounds); | 158 return window1_bounds.Intersects(window2_bounds); |
| 159 } | 159 } |
| 160 | 160 |
| 161 WindowSelectorController* window_selector_controller() { | 161 WindowSelectorController* window_selector_controller() { |
| 162 return WmShell::Get()->window_selector_controller(); | 162 return Shell::Get()->window_selector_controller(); |
| 163 } | 163 } |
| 164 | 164 |
| 165 WindowSelector* window_selector() { | 165 WindowSelector* window_selector() { |
| 166 return window_selector_controller()->window_selector_.get(); | 166 return window_selector_controller()->window_selector_.get(); |
| 167 } | 167 } |
| 168 | 168 |
| 169 void ToggleOverview() { window_selector_controller()->ToggleOverview(); } | 169 void ToggleOverview() { window_selector_controller()->ToggleOverview(); } |
| 170 | 170 |
| 171 aura::Window* GetOverviewWindowForMinimizedState(int index, | 171 aura::Window* GetOverviewWindowForMinimizedState(int index, |
| 172 aura::Window* window) { | 172 aura::Window* window) { |
| (...skipping 1686 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1859 aura::client::WINDOW_MOVE_SOURCE_MOUSE)); | 1859 aura::client::WINDOW_MOVE_SOURCE_MOUSE)); |
| 1860 ASSERT_TRUE(resizer.get()); | 1860 ASSERT_TRUE(resizer.get()); |
| 1861 gfx::Point location = resizer->GetInitialLocation(); | 1861 gfx::Point location = resizer->GetInitialLocation(); |
| 1862 location.Offset(20, 20); | 1862 location.Offset(20, 20); |
| 1863 resizer->Drag(location, 0); | 1863 resizer->Drag(location, 0); |
| 1864 ToggleOverview(); | 1864 ToggleOverview(); |
| 1865 resizer->RevertDrag(); | 1865 resizer->RevertDrag(); |
| 1866 } | 1866 } |
| 1867 | 1867 |
| 1868 } // namespace ash | 1868 } // namespace ash |
| OLD | NEW |