| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #ifndef UI_VIEWS_MUS_TEST_UTILS_H_ | 5 #ifndef UI_VIEWS_MUS_TEST_UTILS_H_ |
| 6 #define UI_VIEWS_MUS_TEST_UTILS_H_ | 6 #define UI_VIEWS_MUS_TEST_UTILS_H_ |
| 7 | 7 |
| 8 #include "ui/views/mus/window_manager_connection.h" | 8 #include "ui/views/mus/window_manager_connection.h" |
| 9 | 9 |
| 10 namespace views { | 10 namespace views { |
| 11 namespace test { | 11 namespace test { |
| 12 | 12 |
| 13 class WindowManagerConnectionTestApi { | 13 class WindowManagerConnectionTestApi { |
| 14 public: | 14 public: |
| 15 explicit WindowManagerConnectionTestApi(WindowManagerConnection* connection) | 15 explicit WindowManagerConnectionTestApi(WindowManagerConnection* connection) |
| 16 : connection_(connection) {} | 16 : connection_(connection) {} |
| 17 ~WindowManagerConnectionTestApi() {} | 17 ~WindowManagerConnectionTestApi() {} |
| 18 | 18 |
| 19 ui::Window* GetUiWindowAtScreenPoint(const gfx::Point& point) { |
| 20 return connection_->GetUiWindowAtScreenPoint(point); |
| 21 } |
| 22 |
| 19 ScreenMus* screen() { return connection_->screen_.get(); } | 23 ScreenMus* screen() { return connection_->screen_.get(); } |
| 20 | 24 |
| 21 private: | 25 private: |
| 22 WindowManagerConnection* connection_; | 26 WindowManagerConnection* connection_; |
| 23 | 27 |
| 24 DISALLOW_COPY_AND_ASSIGN(WindowManagerConnectionTestApi); | 28 DISALLOW_COPY_AND_ASSIGN(WindowManagerConnectionTestApi); |
| 25 }; | 29 }; |
| 26 | 30 |
| 27 } // namespace test | 31 } // namespace test |
| 28 } // namespace views | 32 } // namespace views |
| 29 | 33 |
| 30 #endif // UI_VIEWS_MUS_TEST_UTILS_H_ | 34 #endif // UI_VIEWS_MUS_TEST_UTILS_H_ |
| OLD | NEW |