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 #ifndef COMPONENTS_TEST_RUNNER_WEB_TEST_DELEGATE_H_ | 5 #ifndef COMPONENTS_TEST_RUNNER_WEB_TEST_DELEGATE_H_ |
6 #define COMPONENTS_TEST_RUNNER_WEB_TEST_DELEGATE_H_ | 6 #define COMPONENTS_TEST_RUNNER_WEB_TEST_DELEGATE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 | 151 |
152 // Controls Web Notifications. | 152 // Controls Web Notifications. |
153 virtual void SimulateWebNotificationClick(const std::string& title, | 153 virtual void SimulateWebNotificationClick(const std::string& title, |
154 int action_index) = 0; | 154 int action_index) = 0; |
155 virtual void SimulateWebNotificationClose(const std::string& title, | 155 virtual void SimulateWebNotificationClose(const std::string& title, |
156 bool by_user) = 0; | 156 bool by_user) = 0; |
157 | 157 |
158 // Controls the device scale factor of the main WebView for hidpi tests. | 158 // Controls the device scale factor of the main WebView for hidpi tests. |
159 virtual void SetDeviceScaleFactor(float factor) = 0; | 159 virtual void SetDeviceScaleFactor(float factor) = 0; |
160 | 160 |
| 161 // When use-zoom-for-dsf mode is enabled, this returns the scale to |
| 162 // convert from window coordinates to viewport coordinates. When |
| 163 // use-zoom-for-dsf is disabled, this return always 1.0f. |
| 164 virtual float GetWindowToViewportScale() = 0; |
| 165 |
161 // Enable zoom-for-dsf option. | 166 // Enable zoom-for-dsf option. |
162 virtual void EnableUseZoomForDSF() = 0; | 167 virtual void EnableUseZoomForDSF() = 0; |
163 | 168 |
164 // Returns whether or not the use-zoom-for-dsf flag is enabled. | 169 // Returns whether or not the use-zoom-for-dsf flag is enabled. |
165 virtual bool IsUseZoomForDSFEnabled() = 0; | 170 virtual bool IsUseZoomForDSFEnabled() = 0; |
166 | 171 |
167 // Change the device color profile while running a layout test. | 172 // Change the device color profile while running a layout test. |
168 virtual void SetDeviceColorProfile(const std::string& name) = 0; | 173 virtual void SetDeviceColorProfile(const std::string& name) = 0; |
169 | 174 |
170 // Set the bluetooth adapter while running a layout test, uses Mojo to | 175 // Set the bluetooth adapter while running a layout test, uses Mojo to |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
269 | 274 |
270 virtual float GetDeviceScaleFactorForTest() const = 0; | 275 virtual float GetDeviceScaleFactorForTest() const = 0; |
271 | 276 |
272 // Run all pending idle tasks, and then run callback. | 277 // Run all pending idle tasks, and then run callback. |
273 virtual void RunIdleTasks(const base::Closure& callback) = 0; | 278 virtual void RunIdleTasks(const base::Closure& callback) = 0; |
274 }; | 279 }; |
275 | 280 |
276 } // namespace test_runner | 281 } // namespace test_runner |
277 | 282 |
278 #endif // COMPONENTS_TEST_RUNNER_WEB_TEST_DELEGATE_H_ | 283 #endif // COMPONENTS_TEST_RUNNER_WEB_TEST_DELEGATE_H_ |
OLD | NEW |