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 #ifndef WEBKIT_SUPPORT_WEBKIT_SUPPORT_H_ | 5 #ifndef WEBKIT_SUPPORT_WEBKIT_SUPPORT_H_ |
6 #define WEBKIT_SUPPORT_WEBKIT_SUPPORT_H_ | 6 #define WEBKIT_SUPPORT_WEBKIT_SUPPORT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
118 const WebKit::WebGraphicsContext3D::Attributes& attributes, | 118 const WebKit::WebGraphicsContext3D::Attributes& attributes, |
119 WebKit::WebView* web_view); | 119 WebKit::WebView* web_view); |
120 | 120 |
121 // ------- URL load mocking. | 121 // ------- URL load mocking. |
122 // Registers the file at |file_path| to be served when |url| is requested. | 122 // Registers the file at |file_path| to be served when |url| is requested. |
123 // |response| is the response provided with the contents. | 123 // |response| is the response provided with the contents. |
124 void RegisterMockedURL(const WebKit::WebURL& url, | 124 void RegisterMockedURL(const WebKit::WebURL& url, |
125 const WebKit::WebURLResponse& response, | 125 const WebKit::WebURLResponse& response, |
126 const WebKit::WebString& file_path); | 126 const WebKit::WebString& file_path); |
127 | 127 |
| 128 // Registers the error to be returned when |url| is requested. |
| 129 void RegisterMockedErrorURL(const WebKit::WebURL& url, |
| 130 const WebKit::WebURLResponse& response, |
| 131 const WebKit::WebURLError& error); |
| 132 |
128 // Unregisters URLs so they are no longer mocked. | 133 // Unregisters URLs so they are no longer mocked. |
129 void UnregisterMockedURL(const WebKit::WebURL& url); | 134 void UnregisterMockedURL(const WebKit::WebURL& url); |
130 void UnregisterAllMockedURLs(); | 135 void UnregisterAllMockedURLs(); |
131 | 136 |
132 // Causes all pending asynchronous requests to be served. When this method | 137 // Causes all pending asynchronous requests to be served. When this method |
133 // returns all the pending requests have been processed. | 138 // returns all the pending requests have been processed. |
134 void ServeAsynchronousMockedRequests(); | 139 void ServeAsynchronousMockedRequests(); |
135 | 140 |
136 // Returns the last request that handled by |ServeAsynchronousMockedRequests()|. | 141 // Returns the last request that handled by |ServeAsynchronousMockedRequests()|. |
137 WebKit::WebURLRequest GetLastHandledAsynchronousMockedRequest(); | 142 WebKit::WebURLRequest GetLastHandledAsynchronousMockedRequest(); |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
264 | 269 |
265 void EnableWebCoreLogChannels(const std::string& channels); | 270 void EnableWebCoreLogChannels(const std::string& channels); |
266 | 271 |
267 // - Gamepad | 272 // - Gamepad |
268 | 273 |
269 void SetGamepadData(const WebKit::WebGamepads& pads); | 274 void SetGamepadData(const WebKit::WebGamepads& pads); |
270 | 275 |
271 } // namespace webkit_support | 276 } // namespace webkit_support |
272 | 277 |
273 #endif // WEBKIT_SUPPORT_WEBKIT_SUPPORT_H_ | 278 #endif // WEBKIT_SUPPORT_WEBKIT_SUPPORT_H_ |
OLD | NEW |