Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(267)

Side by Side Diff: services/ui/public/cpp/tests/window_server_test_base.h

Issue 2447303002: Scale client area, hit test mask and bounds by device_scale_factor. (Closed)
Patch Set: rebase Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 SERVICES_UI_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_ 5 #ifndef SERVICES_UI_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_
6 #define SERVICES_UI_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_ 6 #define SERVICES_UI_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <set> 9 #include <set>
10 10
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "services/service_manager/public/cpp/interface_factory.h" 12 #include "services/service_manager/public/cpp/interface_factory.h"
13 #include "services/ui/public/cpp/tests/window_server_shelltest_base.h" 13 #include "services/ui/public/cpp/tests/window_server_shelltest_base.h"
14 #include "services/ui/public/cpp/window_manager_delegate.h" 14 #include "services/ui/public/cpp/window_manager_delegate.h"
15 #include "services/ui/public/cpp/window_tree_client_delegate.h" 15 #include "services/ui/public/cpp/window_tree_client_delegate.h"
16 #include "services/ui/public/interfaces/window_tree.mojom.h" 16 #include "services/ui/public/interfaces/window_tree.mojom.h"
17 #include "ui/display/test/test_screen.h"
17 18
18 namespace ui { 19 namespace ui {
19 20
20 // WindowServerTestBase is a base class for use with shell tests that use 21 // WindowServerTestBase is a base class for use with shell tests that use
21 // WindowServer. SetUp() connects to the WindowServer and blocks until OnEmbed() 22 // WindowServer. SetUp() connects to the WindowServer and blocks until OnEmbed()
22 // has been invoked. window_manager() can be used to access the WindowServer 23 // has been invoked. window_manager() can be used to access the WindowServer
23 // established as part of SetUp(). 24 // established as part of SetUp().
24 class WindowServerTestBase 25 class WindowServerTestBase
25 : public WindowServerServiceTestBase, 26 : public WindowServerServiceTestBase,
26 public WindowTreeClientDelegate, 27 public WindowTreeClientDelegate,
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 // The window server connection held by the window manager (app running at 104 // The window server connection held by the window manager (app running at
104 // the root window). 105 // the root window).
105 WindowTreeClient* window_manager_; 106 WindowTreeClient* window_manager_;
106 107
107 // A test can override the WM-related behaviour by installing its own 108 // A test can override the WM-related behaviour by installing its own
108 // WindowManagerDelegate during the test. 109 // WindowManagerDelegate during the test.
109 WindowManagerDelegate* window_manager_delegate_; 110 WindowManagerDelegate* window_manager_delegate_;
110 111
111 WindowManagerClient* window_manager_client_; 112 WindowManagerClient* window_manager_client_;
112 113
114 // Dummy screen required to be the screen instance.
115 display::test::TestScreen test_screen_;
116
113 bool window_tree_client_lost_connection_ = false; 117 bool window_tree_client_lost_connection_ = false;
114 118
115 DISALLOW_COPY_AND_ASSIGN(WindowServerTestBase); 119 DISALLOW_COPY_AND_ASSIGN(WindowServerTestBase);
116 }; 120 };
117 121
118 } // namespace ui 122 } // namespace ui
119 123
120 #endif // SERVICES_UI_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_ 124 #endif // SERVICES_UI_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_
OLDNEW
« no previous file with comments | « services/ui/public/cpp/tests/BUILD.gn ('k') | services/ui/public/cpp/tests/window_server_test_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698