OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "ash/wm/drag_window_resizer.h" | 5 #include "ash/wm/drag_window_resizer.h" |
6 | 6 |
7 #include "ash/display/mouse_cursor_event_filter.h" | 7 #include "ash/display/mouse_cursor_event_filter.h" |
8 #include "ash/root_window_controller.h" | 8 #include "ash/root_window_controller.h" |
9 #include "ash/shelf/shelf_layout_manager.h" | 9 #include "ash/shelf/shelf_layout_manager.h" |
10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
105 | 105 |
106 internal::ShelfLayoutManager* shelf_layout_manager() { | 106 internal::ShelfLayoutManager* shelf_layout_manager() { |
107 return Shell::GetPrimaryRootWindowController()->GetShelfLayoutManager(); | 107 return Shell::GetPrimaryRootWindowController()->GetShelfLayoutManager(); |
108 } | 108 } |
109 | 109 |
110 static DragWindowResizer* CreateDragWindowResizer( | 110 static DragWindowResizer* CreateDragWindowResizer( |
111 aura::Window* window, | 111 aura::Window* window, |
112 const gfx::Point& point_in_parent, | 112 const gfx::Point& point_in_parent, |
113 int window_component) { | 113 int window_component) { |
114 return static_cast<DragWindowResizer*>(CreateWindowResizer( | 114 return static_cast<DragWindowResizer*>(CreateWindowResizer( |
115 window, point_in_parent, window_component).release()); | 115 window, point_in_parent, window_component, |
| 116 aura::client::WINDOW_MOVE_SOURCE_MOUSE).release()); |
116 } | 117 } |
117 | 118 |
118 aura::test::TestWindowDelegate delegate_; | 119 aura::test::TestWindowDelegate delegate_; |
119 aura::test::TestWindowDelegate delegate2_; | 120 aura::test::TestWindowDelegate delegate2_; |
120 aura::test::TestWindowDelegate delegate3_; | 121 aura::test::TestWindowDelegate delegate3_; |
121 aura::test::TestWindowDelegate delegate4_; | 122 aura::test::TestWindowDelegate delegate4_; |
122 aura::test::TestWindowDelegate delegate5_; | 123 aura::test::TestWindowDelegate delegate5_; |
123 aura::test::TestWindowDelegate delegate6_; | 124 aura::test::TestWindowDelegate delegate6_; |
124 | 125 |
125 scoped_ptr<aura::Window> window_; | 126 scoped_ptr<aura::Window> window_; |
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
498 ASSERT_TRUE(resizer.get()); | 499 ASSERT_TRUE(resizer.get()); |
499 resizer->Drag(CalculateDragPoint(*resizer, 399, 200), 0); | 500 resizer->Drag(CalculateDragPoint(*resizer, 399, 200), 0); |
500 EXPECT_TRUE(event_filter->WarpMouseCursorIfNecessary(root_windows[0], | 501 EXPECT_TRUE(event_filter->WarpMouseCursorIfNecessary(root_windows[0], |
501 gfx::Point(399, 200))); | 502 gfx::Point(399, 200))); |
502 resizer->CompleteDrag(0); | 503 resizer->CompleteDrag(0); |
503 } | 504 } |
504 } | 505 } |
505 | 506 |
506 } // namespace internal | 507 } // namespace internal |
507 } // namespace ash | 508 } // namespace ash |
OLD | NEW |