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/workspace/multi_window_resize_controller.h" | 5 #include "ash/wm/workspace/multi_window_resize_controller.h" |
6 | 6 |
7 #include "ash/ash_constants.h" | 7 #include "ash/ash_constants.h" |
8 #include "ash/frame/custom_frame_view_ash.h" | 8 #include "ash/frame/custom_frame_view_ash.h" |
9 #include "ash/shell.h" | 9 #include "ash/shell.h" |
10 #include "ash/test/ash_test_base.h" | 10 #include "ash/test/ash_test_base.h" |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 WorkspaceControllerTestHelper(wc).GetEventHandler(); | 61 WorkspaceControllerTestHelper(wc).GetEventHandler(); |
62 resize_controller_ = WorkspaceEventHandlerTestHelper(event_handler). | 62 resize_controller_ = WorkspaceEventHandlerTestHelper(event_handler). |
63 resize_controller(); | 63 resize_controller(); |
64 } | 64 } |
65 | 65 |
66 protected: | 66 protected: |
67 aura::Window* CreateTestWindow(aura::WindowDelegate* delegate, | 67 aura::Window* CreateTestWindow(aura::WindowDelegate* delegate, |
68 const gfx::Rect& bounds) { | 68 const gfx::Rect& bounds) { |
69 aura::Window* window = new aura::Window(delegate); | 69 aura::Window* window = new aura::Window(delegate); |
70 window->SetType(ui::wm::WINDOW_TYPE_NORMAL); | 70 window->SetType(ui::wm::WINDOW_TYPE_NORMAL); |
71 window->Init(aura::WINDOW_LAYER_TEXTURED); | 71 window->Init(ui::LAYER_TEXTURED); |
72 ParentWindowInPrimaryRootWindow(window); | 72 ParentWindowInPrimaryRootWindow(window); |
73 window->SetBounds(bounds); | 73 window->SetBounds(bounds); |
74 window->Show(); | 74 window->Show(); |
75 return window; | 75 return window; |
76 } | 76 } |
77 | 77 |
78 void ShowNow() { | 78 void ShowNow() { |
79 resize_controller_->ShowNow(); | 79 resize_controller_->ShowNow(); |
80 } | 80 } |
81 | 81 |
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
367 | 367 |
368 // Clicking outside the resize handle should immediately hide the resize | 368 // Clicking outside the resize handle should immediately hide the resize |
369 // handle. | 369 // handle. |
370 EXPECT_FALSE(resize_widget_bounds_in_screen.Contains(w1_center_in_screen)); | 370 EXPECT_FALSE(resize_widget_bounds_in_screen.Contains(w1_center_in_screen)); |
371 generator.MoveMouseTo(w1_center_in_screen); | 371 generator.MoveMouseTo(w1_center_in_screen); |
372 generator.ClickLeftButton(); | 372 generator.ClickLeftButton(); |
373 EXPECT_FALSE(IsShowing()); | 373 EXPECT_FALSE(IsShowing()); |
374 } | 374 } |
375 | 375 |
376 } // namespace ash | 376 } // namespace ash |
OLD | NEW |