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 CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTDELEGATE_H_ | 5 #ifndef CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTDELEGATE_H_ |
6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTDELEGATE_H_ | 6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTDELEGATE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "third_party/WebKit/public/platform/WebScreenOrientationType.h" | 10 #include "third_party/WebKit/public/platform/WebScreenOrientationType.h" |
11 #include "third_party/WebKit/public/platform/WebString.h" | 11 #include "third_party/WebKit/public/platform/WebString.h" |
12 #include "third_party/WebKit/public/platform/WebURL.h" | 12 #include "third_party/WebKit/public/platform/WebURL.h" |
13 #include "third_party/WebKit/public/platform/WebVector.h" | 13 #include "third_party/WebKit/public/platform/WebVector.h" |
| 14 #include "third_party/WebKit/public/web/WebNotificationPresenter.h" |
14 | 15 |
15 #define WEBTESTRUNNER_NEW_HISTORY_CAPTURE | 16 #define WEBTESTRUNNER_NEW_HISTORY_CAPTURE |
16 | 17 |
17 namespace blink { | 18 namespace blink { |
18 class WebBatteryStatus; | 19 class WebBatteryStatus; |
19 class WebDeviceMotionData; | 20 class WebDeviceMotionData; |
20 class WebDeviceOrientationData; | 21 class WebDeviceOrientationData; |
21 class WebFrame; | 22 class WebFrame; |
22 class WebGamepad; | 23 class WebGamepad; |
23 class WebGamepads; | 24 class WebGamepads; |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 const std::string& frontend_url) = 0; | 112 const std::string& frontend_url) = 0; |
112 virtual void closeDevTools() = 0; | 113 virtual void closeDevTools() = 0; |
113 | 114 |
114 // Evaluate the given script in the DevTools agent. | 115 // Evaluate the given script in the DevTools agent. |
115 virtual void evaluateInWebInspector(long callID, const std::string& script)
= 0; | 116 virtual void evaluateInWebInspector(long callID, const std::string& script)
= 0; |
116 | 117 |
117 // Controls WebSQL databases. | 118 // Controls WebSQL databases. |
118 virtual void clearAllDatabases() = 0; | 119 virtual void clearAllDatabases() = 0; |
119 virtual void setDatabaseQuota(int) = 0; | 120 virtual void setDatabaseQuota(int) = 0; |
120 | 121 |
| 122 // Controls Web Notification permissions. |
| 123 virtual blink::WebNotificationPresenter::Permission |
| 124 checkWebNotificationPermission(const GURL& origin) = 0; |
| 125 virtual void grantWebNotificationPermission(const GURL& origin, |
| 126 bool permission_granted) = 0; |
| 127 virtual void clearWebNotificationPermissions() = 0; |
| 128 |
121 // Controls the device scale factor of the main WebView for hidpi tests. | 129 // Controls the device scale factor of the main WebView for hidpi tests. |
122 virtual void setDeviceScaleFactor(float) = 0; | 130 virtual void setDeviceScaleFactor(float) = 0; |
123 | 131 |
124 // Change the device color profile while running a layout test. | 132 // Change the device color profile while running a layout test. |
125 virtual void setDeviceColorProfile(const std::string& name) = 0; | 133 virtual void setDeviceColorProfile(const std::string& name) = 0; |
126 | 134 |
127 // Controls which WebView should be focused. | 135 // Controls which WebView should be focused. |
128 virtual void setFocus(WebTestProxyBase*, bool) = 0; | 136 virtual void setFocus(WebTestProxyBase*, bool) = 0; |
129 | 137 |
130 // Controls whether all cookies should be accepted or writing cookies in a | 138 // Controls whether all cookies should be accepted or writing cookies in a |
(...skipping 27 matching lines...) Expand all Loading... |
158 virtual bool allowExternalPages() = 0; | 166 virtual bool allowExternalPages() = 0; |
159 | 167 |
160 // Returns a text dump the back/forward history for the WebView associated | 168 // Returns a text dump the back/forward history for the WebView associated |
161 // with the given WebTestProxyBase. | 169 // with the given WebTestProxyBase. |
162 virtual std::string dumpHistoryForWindow(WebTestProxyBase*) = 0; | 170 virtual std::string dumpHistoryForWindow(WebTestProxyBase*) = 0; |
163 }; | 171 }; |
164 | 172 |
165 } // namespace content | 173 } // namespace content |
166 | 174 |
167 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTDELEGATE_H_ | 175 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTDELEGATE_H_ |
OLD | NEW |