| 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_WEBTESTPROXY_H_ | 5 #ifndef CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTPROXY_H_ |
| 6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTPROXY_H_ | 6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTPROXY_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
| 12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
| 13 #include "content/shell/renderer/test_runner/WebTask.h" | 13 #include "content/shell/renderer/test_runner/WebTask.h" |
| 14 #include "third_party/WebKit/public/platform/WebRect.h" | 14 #include "third_party/WebKit/public/platform/WebRect.h" |
| 15 #include "third_party/WebKit/public/platform/WebURLError.h" | 15 #include "third_party/WebKit/public/platform/WebURLError.h" |
| 16 #include "third_party/WebKit/public/platform/WebURLRequest.h" | 16 #include "third_party/WebKit/public/platform/WebURLRequest.h" |
| 17 #include "third_party/WebKit/public/web/WebAXEnums.h" | 17 #include "third_party/WebKit/public/web/WebAXEnums.h" |
| 18 #include "third_party/WebKit/public/web/WebDOMMessageEvent.h" | 18 #include "third_party/WebKit/public/web/WebDOMMessageEvent.h" |
| 19 #include "third_party/WebKit/public/web/WebDataSource.h" | 19 #include "third_party/WebKit/public/web/WebDataSource.h" |
| 20 #include "third_party/WebKit/public/web/WebDragOperation.h" | 20 #include "third_party/WebKit/public/web/WebDragOperation.h" |
| 21 #include "third_party/WebKit/public/web/WebFrame.h" |
| 21 #include "third_party/WebKit/public/web/WebIconURL.h" | 22 #include "third_party/WebKit/public/web/WebIconURL.h" |
| 23 // TODO(dcheng): Temporary. Delete once forward declarable. |
| 24 #include "third_party/WebKit/public/web/WebLocalFrame.h" |
| 22 #include "third_party/WebKit/public/web/WebNavigationPolicy.h" | 25 #include "third_party/WebKit/public/web/WebNavigationPolicy.h" |
| 23 #include "third_party/WebKit/public/web/WebNavigationType.h" | 26 #include "third_party/WebKit/public/web/WebNavigationType.h" |
| 24 #include "third_party/WebKit/public/web/WebSecurityOrigin.h" | 27 #include "third_party/WebKit/public/web/WebSecurityOrigin.h" |
| 25 #include "third_party/WebKit/public/web/WebTextAffinity.h" | 28 #include "third_party/WebKit/public/web/WebTextAffinity.h" |
| 26 #include "third_party/WebKit/public/web/WebTextDirection.h" | 29 #include "third_party/WebKit/public/web/WebTextDirection.h" |
| 27 | 30 |
| 28 namespace blink { | 31 namespace blink { |
| 29 class WebAXObject; | 32 class WebAXObject; |
| 30 class WebAudioDevice; | 33 class WebAudioDevice; |
| 31 class WebCachedURLRequest; | 34 class WebCachedURLRequest; |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 132 | 135 |
| 133 void didInvalidateRect(const blink::WebRect&); | 136 void didInvalidateRect(const blink::WebRect&); |
| 134 void didScrollRect(int, int, const blink::WebRect&); | 137 void didScrollRect(int, int, const blink::WebRect&); |
| 135 void scheduleAnimation(); | 138 void scheduleAnimation(); |
| 136 bool isCompositorFramePending() const; | 139 bool isCompositorFramePending() const; |
| 137 // FIXME: Remove once we switch to use didForceResize. | 140 // FIXME: Remove once we switch to use didForceResize. |
| 138 void setWindowRect(const blink::WebRect&); | 141 void setWindowRect(const blink::WebRect&); |
| 139 void show(blink::WebNavigationPolicy); | 142 void show(blink::WebNavigationPolicy); |
| 140 void didAutoResize(const blink::WebSize&); | 143 void didAutoResize(const blink::WebSize&); |
| 141 void postAccessibilityEvent(const blink::WebAXObject&, blink::WebAXEvent); | 144 void postAccessibilityEvent(const blink::WebAXObject&, blink::WebAXEvent); |
| 142 void startDragging(blink::WebFrame*, const blink::WebDragData&, blink::WebDr
agOperationsMask, const blink::WebImage&, const blink::WebPoint&); | 145 void startDragging(blink::WebLocalFrame*, const blink::WebDragData&, blink::
WebDragOperationsMask, const blink::WebImage&, const blink::WebPoint&); |
| 143 void didChangeSelection(bool isEmptySelection); | 146 void didChangeSelection(bool isEmptySelection); |
| 144 void didChangeContents(); | 147 void didChangeContents(); |
| 145 void didEndEditing(); | 148 void didEndEditing(); |
| 146 bool createView(blink::WebFrame* creator, const blink::WebURLRequest&, const
blink::WebWindowFeatures&, const blink::WebString& frameName, blink::WebNavigat
ionPolicy, bool suppressOpener); | 149 bool createView(blink::WebLocalFrame* creator, const blink::WebURLRequest&,
const blink::WebWindowFeatures&, const blink::WebString& frameName, blink::WebNa
vigationPolicy, bool suppressOpener); |
| 147 blink::WebPlugin* createPlugin(blink::WebFrame*, const blink::WebPluginParam
s&); | 150 blink::WebPlugin* createPlugin(blink::WebLocalFrame*, const blink::WebPlugin
Params&); |
| 148 void setStatusText(const blink::WebString&); | 151 void setStatusText(const blink::WebString&); |
| 149 void didStopLoading(); | 152 void didStopLoading(); |
| 150 void showContextMenu(blink::WebFrame*, const blink::WebContextMenuData&); | 153 void showContextMenu(blink::WebLocalFrame*, const blink::WebContextMenuData&
); |
| 151 blink::WebUserMediaClient* userMediaClient(); | 154 blink::WebUserMediaClient* userMediaClient(); |
| 152 void printPage(blink::WebFrame*); | 155 void printPage(blink::WebLocalFrame*); |
| 153 blink::WebNotificationPresenter* notificationPresenter(); | 156 blink::WebNotificationPresenter* notificationPresenter(); |
| 154 blink::WebMIDIClient* webMIDIClient(); | 157 blink::WebMIDIClient* webMIDIClient(); |
| 155 blink::WebSpeechInputController* speechInputController(blink::WebSpeechInput
Listener*); | 158 blink::WebSpeechInputController* speechInputController(blink::WebSpeechInput
Listener*); |
| 156 blink::WebSpeechRecognizer* speechRecognizer(); | 159 blink::WebSpeechRecognizer* speechRecognizer(); |
| 157 bool requestPointerLock(); | 160 bool requestPointerLock(); |
| 158 void requestPointerUnlock(); | 161 void requestPointerUnlock(); |
| 159 bool isPointerLocked(); | 162 bool isPointerLocked(); |
| 160 void didFocus(); | 163 void didFocus(); |
| 161 void didBlur(); | 164 void didBlur(); |
| 162 void setToolTipText(const blink::WebString&, blink::WebTextDirection); | 165 void setToolTipText(const blink::WebString&, blink::WebTextDirection); |
| 163 void didAddMessageToConsole(const blink::WebConsoleMessage&, const blink::We
bString& sourceName, unsigned sourceLine); | 166 void didAddMessageToConsole(const blink::WebConsoleMessage&, const blink::We
bString& sourceName, unsigned sourceLine); |
| 164 void runModalAlertDialog(blink::WebFrame*, const blink::WebString&); | 167 void runModalAlertDialog(blink::WebLocalFrame*, const blink::WebString&); |
| 165 bool runModalConfirmDialog(blink::WebFrame*, const blink::WebString&); | 168 bool runModalConfirmDialog(blink::WebLocalFrame*, const blink::WebString&); |
| 166 bool runModalPromptDialog(blink::WebFrame*, const blink::WebString& message,
const blink::WebString& defaultValue, blink::WebString* actualValue); | 169 bool runModalPromptDialog(blink::WebLocalFrame*, const blink::WebString& mes
sage, const blink::WebString& defaultValue, blink::WebString* actualValue); |
| 167 bool runModalBeforeUnloadDialog(blink::WebFrame*, const blink::WebString&); | 170 bool runModalBeforeUnloadDialog(blink::WebLocalFrame*, const blink::WebStrin
g&); |
| 168 | 171 |
| 169 void didStartProvisionalLoad(blink::WebFrame*); | 172 void didStartProvisionalLoad(blink::WebLocalFrame*); |
| 170 void didReceiveServerRedirectForProvisionalLoad(blink::WebFrame*); | 173 void didReceiveServerRedirectForProvisionalLoad(blink::WebLocalFrame*); |
| 171 bool didFailProvisionalLoad(blink::WebFrame*, const blink::WebURLError&); | 174 bool didFailProvisionalLoad(blink::WebLocalFrame*, const blink::WebURLError&
); |
| 172 void didCommitProvisionalLoad(blink::WebFrame*, bool isNewNavigation); | 175 void didCommitProvisionalLoad(blink::WebLocalFrame*, bool isNewNavigation); |
| 173 void didReceiveTitle(blink::WebFrame*, const blink::WebString& title, blink:
:WebTextDirection); | 176 void didReceiveTitle(blink::WebLocalFrame*, const blink::WebString& title, b
link::WebTextDirection); |
| 174 void didChangeIcon(blink::WebFrame*, blink::WebIconURL::Type); | 177 void didChangeIcon(blink::WebLocalFrame*, blink::WebIconURL::Type); |
| 175 void didFinishDocumentLoad(blink::WebFrame*); | 178 void didFinishDocumentLoad(blink::WebLocalFrame*); |
| 176 void didHandleOnloadEvents(blink::WebFrame*); | 179 void didHandleOnloadEvents(blink::WebLocalFrame*); |
| 177 void didFailLoad(blink::WebFrame*, const blink::WebURLError&); | 180 void didFailLoad(blink::WebLocalFrame*, const blink::WebURLError&); |
| 178 void didFinishLoad(blink::WebFrame*); | 181 void didFinishLoad(blink::WebLocalFrame*); |
| 179 void didChangeLocationWithinPage(blink::WebFrame*); | 182 void didChangeLocationWithinPage(blink::WebLocalFrame*); |
| 180 void didDetectXSS(blink::WebFrame*, const blink::WebURL& insecureURL, bool d
idBlockEntirePage); | 183 void didDetectXSS(blink::WebLocalFrame*, const blink::WebURL& insecureURL, b
ool didBlockEntirePage); |
| 181 void didDispatchPingLoader(blink::WebFrame*, const blink::WebURL&); | 184 void didDispatchPingLoader(blink::WebLocalFrame*, const blink::WebURL&); |
| 182 void willRequestResource(blink::WebFrame*, const blink::WebCachedURLRequest&
); | 185 void willRequestResource(blink::WebLocalFrame*, const blink::WebCachedURLReq
uest&); |
| 183 void willSendRequest(blink::WebFrame*, unsigned identifier, blink::WebURLReq
uest&, const blink::WebURLResponse& redirectResponse); | 186 void willSendRequest(blink::WebLocalFrame*, unsigned identifier, blink::WebU
RLRequest&, const blink::WebURLResponse& redirectResponse); |
| 184 void didReceiveResponse(blink::WebFrame*, unsigned identifier, const blink::
WebURLResponse&); | 187 void didReceiveResponse(blink::WebLocalFrame*, unsigned identifier, const bl
ink::WebURLResponse&); |
| 185 void didChangeResourcePriority(blink::WebFrame*, unsigned identifier, const
blink::WebURLRequest::Priority&); | 188 void didChangeResourcePriority(blink::WebLocalFrame*, unsigned identifier, c
onst blink::WebURLRequest::Priority&); |
| 186 void didFinishResourceLoad(blink::WebFrame*, unsigned identifier); | 189 void didFinishResourceLoad(blink::WebLocalFrame*, unsigned identifier); |
| 187 blink::WebNavigationPolicy decidePolicyForNavigation(blink::WebFrame*, blink
::WebDataSource::ExtraData*, const blink::WebURLRequest&, blink::WebNavigationTy
pe, blink::WebNavigationPolicy defaultPolicy, bool isRedirect); | 190 blink::WebNavigationPolicy decidePolicyForNavigation(blink::WebLocalFrame*,
blink::WebDataSource::ExtraData*, const blink::WebURLRequest&, blink::WebNavigat
ionType, blink::WebNavigationPolicy defaultPolicy, bool isRedirect); |
| 188 bool willCheckAndDispatchMessageEvent(blink::WebFrame* sourceFrame, blink::W
ebFrame* targetFrame, blink::WebSecurityOrigin target, blink::WebDOMMessageEvent
); | 191 bool willCheckAndDispatchMessageEvent(blink::WebLocalFrame* sourceFrame, bli
nk::WebFrame* targetFrame, blink::WebSecurityOrigin target, blink::WebDOMMessage
Event); |
| 189 void resetInputMethod(); | 192 void resetInputMethod(); |
| 190 | 193 |
| 191 private: | 194 private: |
| 192 template<class, typename, typename> friend class WebFrameTestProxy; | 195 template<class, typename, typename> friend class WebFrameTestProxy; |
| 193 void locationChangeDone(blink::WebFrame*); | 196 void locationChangeDone(blink::WebFrame*); |
| 194 void paintRect(const blink::WebRect&); | 197 void paintRect(const blink::WebRect&); |
| 195 void paintInvalidatedRegion(); | 198 void paintInvalidatedRegion(); |
| 196 void paintPagesWithBoundaries(); | 199 void paintPagesWithBoundaries(); |
| 197 SkCanvas* canvas(); | 200 SkCanvas* canvas(); |
| 198 void displayRepaintMask(); | 201 void displayRepaintMask(); |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 275 virtual void didAutoResize(const blink::WebSize& newSize) | 278 virtual void didAutoResize(const blink::WebSize& newSize) |
| 276 { | 279 { |
| 277 WebTestProxyBase::didAutoResize(newSize); | 280 WebTestProxyBase::didAutoResize(newSize); |
| 278 Base::didAutoResize(newSize); | 281 Base::didAutoResize(newSize); |
| 279 } | 282 } |
| 280 virtual void postAccessibilityEvent(const blink::WebAXObject& object, blink:
:WebAXEvent event) | 283 virtual void postAccessibilityEvent(const blink::WebAXObject& object, blink:
:WebAXEvent event) |
| 281 { | 284 { |
| 282 WebTestProxyBase::postAccessibilityEvent(object, event); | 285 WebTestProxyBase::postAccessibilityEvent(object, event); |
| 283 Base::postAccessibilityEvent(object, event); | 286 Base::postAccessibilityEvent(object, event); |
| 284 } | 287 } |
| 285 virtual void startDragging(blink::WebFrame* frame, const blink::WebDragData&
data, blink::WebDragOperationsMask mask, const blink::WebImage& image, const bl
ink::WebPoint& point) | 288 virtual void startDragging(blink::WebLocalFrame* frame, const blink::WebDrag
Data& data, blink::WebDragOperationsMask mask, const blink::WebImage& image, con
st blink::WebPoint& point) |
| 286 { | 289 { |
| 287 WebTestProxyBase::startDragging(frame, data, mask, image, point); | 290 WebTestProxyBase::startDragging(frame, data, mask, image, point); |
| 288 // Don't forward this call to Base because we don't want to do a real dr
ag-and-drop. | 291 // Don't forward this call to Base because we don't want to do a real dr
ag-and-drop. |
| 289 } | 292 } |
| 290 virtual void didChangeContents() | 293 virtual void didChangeContents() |
| 291 { | 294 { |
| 292 WebTestProxyBase::didChangeContents(); | 295 WebTestProxyBase::didChangeContents(); |
| 293 Base::didChangeContents(); | 296 Base::didChangeContents(); |
| 294 } | 297 } |
| 295 virtual blink::WebView* createView(blink::WebFrame* creator, const blink::We
bURLRequest& request, const blink::WebWindowFeatures& features, const blink::Web
String& frameName, blink::WebNavigationPolicy policy, bool suppressOpener) | 298 virtual blink::WebView* createView(blink::WebLocalFrame* creator, const blin
k::WebURLRequest& request, const blink::WebWindowFeatures& features, const blink
::WebString& frameName, blink::WebNavigationPolicy policy, bool suppressOpener) |
| 296 { | 299 { |
| 297 if (!WebTestProxyBase::createView(creator, request, features, frameName,
policy, suppressOpener)) | 300 if (!WebTestProxyBase::createView(creator, request, features, frameName,
policy, suppressOpener)) |
| 298 return 0; | 301 return 0; |
| 299 return Base::createView(creator, request, features, frameName, policy, s
uppressOpener); | 302 return Base::createView(creator, request, features, frameName, policy, s
uppressOpener); |
| 300 } | 303 } |
| 301 virtual void setStatusText(const blink::WebString& text) | 304 virtual void setStatusText(const blink::WebString& text) |
| 302 { | 305 { |
| 303 WebTestProxyBase::setStatusText(text); | 306 WebTestProxyBase::setStatusText(text); |
| 304 Base::setStatusText(text); | 307 Base::setStatusText(text); |
| 305 } | 308 } |
| 306 virtual blink::WebUserMediaClient* userMediaClient() | 309 virtual blink::WebUserMediaClient* userMediaClient() |
| 307 { | 310 { |
| 308 return WebTestProxyBase::userMediaClient(); | 311 return WebTestProxyBase::userMediaClient(); |
| 309 } | 312 } |
| 310 virtual void printPage(blink::WebFrame* frame) | 313 virtual void printPage(blink::WebLocalFrame* frame) |
| 311 { | 314 { |
| 312 WebTestProxyBase::printPage(frame); | 315 WebTestProxyBase::printPage(frame); |
| 313 } | 316 } |
| 314 virtual blink::WebNotificationPresenter* notificationPresenter() | 317 virtual blink::WebNotificationPresenter* notificationPresenter() |
| 315 { | 318 { |
| 316 return WebTestProxyBase::notificationPresenter(); | 319 return WebTestProxyBase::notificationPresenter(); |
| 317 } | 320 } |
| 318 virtual blink::WebMIDIClient* webMIDIClient() | 321 virtual blink::WebMIDIClient* webMIDIClient() |
| 319 { | 322 { |
| 320 return WebTestProxyBase::webMIDIClient(); | 323 return WebTestProxyBase::webMIDIClient(); |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 352 virtual void setToolTipText(const blink::WebString& text, blink::WebTextDire
ction hint) | 355 virtual void setToolTipText(const blink::WebString& text, blink::WebTextDire
ction hint) |
| 353 { | 356 { |
| 354 WebTestProxyBase::setToolTipText(text, hint); | 357 WebTestProxyBase::setToolTipText(text, hint); |
| 355 Base::setToolTipText(text, hint); | 358 Base::setToolTipText(text, hint); |
| 356 } | 359 } |
| 357 virtual void resetInputMethod() | 360 virtual void resetInputMethod() |
| 358 { | 361 { |
| 359 WebTestProxyBase::resetInputMethod(); | 362 WebTestProxyBase::resetInputMethod(); |
| 360 } | 363 } |
| 361 | 364 |
| 362 virtual void didStartProvisionalLoad(blink::WebFrame* frame) | 365 virtual void didStartProvisionalLoad(blink::WebLocalFrame* frame) |
| 363 { | 366 { |
| 364 WebTestProxyBase::didStartProvisionalLoad(frame); | 367 WebTestProxyBase::didStartProvisionalLoad(frame); |
| 365 Base::didStartProvisionalLoad(frame); | 368 Base::didStartProvisionalLoad(frame); |
| 366 } | 369 } |
| 367 virtual void didReceiveServerRedirectForProvisionalLoad(blink::WebFrame* fra
me) | 370 virtual void didReceiveServerRedirectForProvisionalLoad(blink::WebLocalFrame
* frame) |
| 368 { | 371 { |
| 369 WebTestProxyBase::didReceiveServerRedirectForProvisionalLoad(frame); | 372 WebTestProxyBase::didReceiveServerRedirectForProvisionalLoad(frame); |
| 370 Base::didReceiveServerRedirectForProvisionalLoad(frame); | 373 Base::didReceiveServerRedirectForProvisionalLoad(frame); |
| 371 } | 374 } |
| 372 virtual void didFailProvisionalLoad(blink::WebFrame* frame, const blink::Web
URLError& error) | 375 virtual void didFailProvisionalLoad(blink::WebLocalFrame* frame, const blink
::WebURLError& error) |
| 373 { | 376 { |
| 374 // If the test finished, don't notify the embedder of the failed load, | 377 // If the test finished, don't notify the embedder of the failed load, |
| 375 // as we already destroyed the document loader. | 378 // as we already destroyed the document loader. |
| 376 if (WebTestProxyBase::didFailProvisionalLoad(frame, error)) | 379 if (WebTestProxyBase::didFailProvisionalLoad(frame, error)) |
| 377 return; | 380 return; |
| 378 Base::didFailProvisionalLoad(frame, error); | 381 Base::didFailProvisionalLoad(frame, error); |
| 379 } | 382 } |
| 380 virtual void didCommitProvisionalLoad(blink::WebFrame* frame, bool isNewNavi
gation) | 383 virtual void didCommitProvisionalLoad(blink::WebLocalFrame* frame, bool isNe
wNavigation) |
| 381 { | 384 { |
| 382 WebTestProxyBase::didCommitProvisionalLoad(frame, isNewNavigation); | 385 WebTestProxyBase::didCommitProvisionalLoad(frame, isNewNavigation); |
| 383 Base::didCommitProvisionalLoad(frame, isNewNavigation); | 386 Base::didCommitProvisionalLoad(frame, isNewNavigation); |
| 384 } | 387 } |
| 385 virtual void didReceiveTitle(blink::WebFrame* frame, const blink::WebString&
title, blink::WebTextDirection direction) | 388 virtual void didReceiveTitle(blink::WebLocalFrame* frame, const blink::WebSt
ring& title, blink::WebTextDirection direction) |
| 386 { | 389 { |
| 387 WebTestProxyBase::didReceiveTitle(frame, title, direction); | 390 WebTestProxyBase::didReceiveTitle(frame, title, direction); |
| 388 Base::didReceiveTitle(frame, title, direction); | 391 Base::didReceiveTitle(frame, title, direction); |
| 389 } | 392 } |
| 390 virtual void didChangeIcon(blink::WebFrame* frame, blink::WebIconURL::Type i
conType) | 393 virtual void didChangeIcon(blink::WebLocalFrame* frame, blink::WebIconURL::T
ype iconType) |
| 391 { | 394 { |
| 392 WebTestProxyBase::didChangeIcon(frame, iconType); | 395 WebTestProxyBase::didChangeIcon(frame, iconType); |
| 393 Base::didChangeIcon(frame, iconType); | 396 Base::didChangeIcon(frame, iconType); |
| 394 } | 397 } |
| 395 virtual void didFinishDocumentLoad(blink::WebFrame* frame) | 398 virtual void didFinishDocumentLoad(blink::WebLocalFrame* frame) |
| 396 { | 399 { |
| 397 WebTestProxyBase::didFinishDocumentLoad(frame); | 400 WebTestProxyBase::didFinishDocumentLoad(frame); |
| 398 Base::didFinishDocumentLoad(frame); | 401 Base::didFinishDocumentLoad(frame); |
| 399 } | 402 } |
| 400 virtual void didHandleOnloadEvents(blink::WebFrame* frame) | 403 virtual void didHandleOnloadEvents(blink::WebLocalFrame* frame) |
| 401 { | 404 { |
| 402 WebTestProxyBase::didHandleOnloadEvents(frame); | 405 WebTestProxyBase::didHandleOnloadEvents(frame); |
| 403 Base::didHandleOnloadEvents(frame); | 406 Base::didHandleOnloadEvents(frame); |
| 404 } | 407 } |
| 405 virtual void didFailLoad(blink::WebFrame* frame, const blink::WebURLError& e
rror) | 408 virtual void didFailLoad(blink::WebLocalFrame* frame, const blink::WebURLErr
or& error) |
| 406 { | 409 { |
| 407 WebTestProxyBase::didFailLoad(frame, error); | 410 WebTestProxyBase::didFailLoad(frame, error); |
| 408 Base::didFailLoad(frame, error); | 411 Base::didFailLoad(frame, error); |
| 409 } | 412 } |
| 410 virtual void didFinishLoad(blink::WebFrame* frame) | 413 virtual void didFinishLoad(blink::WebLocalFrame* frame) |
| 411 { | 414 { |
| 412 WebTestProxyBase::didFinishLoad(frame); | 415 WebTestProxyBase::didFinishLoad(frame); |
| 413 Base::didFinishLoad(frame); | 416 Base::didFinishLoad(frame); |
| 414 } | 417 } |
| 415 virtual void didDetectXSS(blink::WebFrame* frame, const blink::WebURL& insec
ureURL, bool didBlockEntirePage) | 418 virtual void didDetectXSS(blink::WebLocalFrame* frame, const blink::WebURL&
insecureURL, bool didBlockEntirePage) |
| 416 { | 419 { |
| 417 WebTestProxyBase::didDetectXSS(frame, insecureURL, didBlockEntirePage); | 420 WebTestProxyBase::didDetectXSS(frame, insecureURL, didBlockEntirePage); |
| 418 Base::didDetectXSS(frame, insecureURL, didBlockEntirePage); | 421 Base::didDetectXSS(frame, insecureURL, didBlockEntirePage); |
| 419 } | 422 } |
| 420 virtual void willRequestResource(blink::WebFrame* frame, const blink::WebCac
hedURLRequest& request) | 423 virtual void willRequestResource(blink::WebLocalFrame* frame, const blink::W
ebCachedURLRequest& request) |
| 421 { | 424 { |
| 422 WebTestProxyBase::willRequestResource(frame, request); | 425 WebTestProxyBase::willRequestResource(frame, request); |
| 423 Base::willRequestResource(frame, request); | 426 Base::willRequestResource(frame, request); |
| 424 } | 427 } |
| 425 virtual void willSendRequest(blink::WebFrame* frame, unsigned identifier, bl
ink::WebURLRequest& request, const blink::WebURLResponse& redirectResponse) | 428 virtual void willSendRequest(blink::WebLocalFrame* frame, unsigned identifie
r, blink::WebURLRequest& request, const blink::WebURLResponse& redirectResponse) |
| 426 { | 429 { |
| 427 WebTestProxyBase::willSendRequest(frame, identifier, request, redirectRe
sponse); | 430 WebTestProxyBase::willSendRequest(frame, identifier, request, redirectRe
sponse); |
| 428 Base::willSendRequest(frame, identifier, request, redirectResponse); | 431 Base::willSendRequest(frame, identifier, request, redirectResponse); |
| 429 } | 432 } |
| 430 virtual void didReceiveResponse(blink::WebFrame* frame, unsigned identifier,
const blink::WebURLResponse& response) | 433 virtual void didReceiveResponse(blink::WebLocalFrame* frame, unsigned identi
fier, const blink::WebURLResponse& response) |
| 431 { | 434 { |
| 432 WebTestProxyBase::didReceiveResponse(frame, identifier, response); | 435 WebTestProxyBase::didReceiveResponse(frame, identifier, response); |
| 433 Base::didReceiveResponse(frame, identifier, response); | 436 Base::didReceiveResponse(frame, identifier, response); |
| 434 } | 437 } |
| 435 virtual void didChangeResourcePriority(blink::WebFrame* frame, unsigned iden
tifier, const blink::WebURLRequest::Priority& priority) | 438 virtual void didChangeResourcePriority(blink::WebLocalFrame* frame, unsigned
identifier, const blink::WebURLRequest::Priority& priority) |
| 436 { | 439 { |
| 437 WebTestProxyBase::didChangeResourcePriority(frame, identifier, priority)
; | 440 WebTestProxyBase::didChangeResourcePriority(frame, identifier, priority)
; |
| 438 Base::didChangeResourcePriority(frame, identifier, priority); | 441 Base::didChangeResourcePriority(frame, identifier, priority); |
| 439 } | 442 } |
| 440 virtual void didFinishResourceLoad(blink::WebFrame* frame, unsigned identifi
er) | 443 virtual void didFinishResourceLoad(blink::WebLocalFrame* frame, unsigned ide
ntifier) |
| 441 { | 444 { |
| 442 WebTestProxyBase::didFinishResourceLoad(frame, identifier); | 445 WebTestProxyBase::didFinishResourceLoad(frame, identifier); |
| 443 Base::didFinishResourceLoad(frame, identifier); | 446 Base::didFinishResourceLoad(frame, identifier); |
| 444 } | 447 } |
| 445 virtual void runModalAlertDialog(blink::WebFrame* frame, const blink::WebStr
ing& message) | 448 virtual void runModalAlertDialog(blink::WebLocalFrame* frame, const blink::W
ebString& message) |
| 446 { | 449 { |
| 447 WebTestProxyBase::runModalAlertDialog(frame, message); | 450 WebTestProxyBase::runModalAlertDialog(frame, message); |
| 448 Base::runModalAlertDialog(frame, message); | 451 Base::runModalAlertDialog(frame, message); |
| 449 } | 452 } |
| 450 virtual bool runModalConfirmDialog(blink::WebFrame* frame, const blink::WebS
tring& message) | 453 virtual bool runModalConfirmDialog(blink::WebLocalFrame* frame, const blink:
:WebString& message) |
| 451 { | 454 { |
| 452 WebTestProxyBase::runModalConfirmDialog(frame, message); | 455 WebTestProxyBase::runModalConfirmDialog(frame, message); |
| 453 return Base::runModalConfirmDialog(frame, message); | 456 return Base::runModalConfirmDialog(frame, message); |
| 454 } | 457 } |
| 455 virtual bool runModalPromptDialog(blink::WebFrame* frame, const blink::WebSt
ring& message, const blink::WebString& defaultValue, blink::WebString* actualVal
ue) | 458 virtual bool runModalPromptDialog(blink::WebLocalFrame* frame, const blink::
WebString& message, const blink::WebString& defaultValue, blink::WebString* actu
alValue) |
| 456 { | 459 { |
| 457 WebTestProxyBase::runModalPromptDialog(frame, message, defaultValue, act
ualValue); | 460 WebTestProxyBase::runModalPromptDialog(frame, message, defaultValue, act
ualValue); |
| 458 return Base::runModalPromptDialog(frame, message, defaultValue, actualVa
lue); | 461 return Base::runModalPromptDialog(frame, message, defaultValue, actualVa
lue); |
| 459 } | 462 } |
| 460 virtual bool runModalBeforeUnloadDialog(blink::WebFrame* frame, const blink:
:WebString& message) | 463 virtual bool runModalBeforeUnloadDialog(blink::WebLocalFrame* frame, const b
link::WebString& message) |
| 461 { | 464 { |
| 462 return WebTestProxyBase::runModalBeforeUnloadDialog(frame, message); | 465 return WebTestProxyBase::runModalBeforeUnloadDialog(frame, message); |
| 463 } | 466 } |
| 464 virtual bool willCheckAndDispatchMessageEvent(blink::WebFrame* sourceFrame,
blink::WebFrame* targetFrame, blink::WebSecurityOrigin target, blink::WebDOMMess
ageEvent event) | 467 virtual bool willCheckAndDispatchMessageEvent(blink::WebLocalFrame* sourceFr
ame, blink::WebFrame* targetFrame, blink::WebSecurityOrigin target, blink::WebDO
MMessageEvent event) |
| 465 { | 468 { |
| 466 if (WebTestProxyBase::willCheckAndDispatchMessageEvent(sourceFrame, targ
etFrame, target, event)) | 469 if (WebTestProxyBase::willCheckAndDispatchMessageEvent(sourceFrame, targ
etFrame, target, event)) |
| 467 return true; | 470 return true; |
| 468 return Base::willCheckAndDispatchMessageEvent(sourceFrame, targetFrame,
target, event); | 471 return Base::willCheckAndDispatchMessageEvent(sourceFrame, targetFrame,
target, event); |
| 469 } | 472 } |
| 470 virtual blink::WebColorChooser* createColorChooser(blink::WebColorChooserCli
ent* client, const blink::WebColor& color) | 473 virtual blink::WebColorChooser* createColorChooser(blink::WebColorChooserCli
ent* client, const blink::WebColor& color) |
| 471 { | 474 { |
| 472 return WebTestProxyBase::createColorChooser(client, color); | 475 return WebTestProxyBase::createColorChooser(client, color); |
| 473 } | 476 } |
| 474 virtual blink::WebColorChooser* createColorChooser(blink::WebColorChooserCli
ent* client, const blink::WebColor& color, const blink::WebVector<blink::WebColo
rSuggestion>& suggestions) | 477 virtual blink::WebColorChooser* createColorChooser(blink::WebColorChooserCli
ent* client, const blink::WebColor& color, const blink::WebVector<blink::WebColo
rSuggestion>& suggestions) |
| (...skipping 21 matching lines...) Expand all Loading... |
| 496 WebTestProxyBase::postSpellCheckEvent(eventName); | 499 WebTestProxyBase::postSpellCheckEvent(eventName); |
| 497 } | 500 } |
| 498 | 501 |
| 499 private: | 502 private: |
| 500 DISALLOW_COPY_AND_ASSIGN(WebTestProxy); | 503 DISALLOW_COPY_AND_ASSIGN(WebTestProxy); |
| 501 }; | 504 }; |
| 502 | 505 |
| 503 } | 506 } |
| 504 | 507 |
| 505 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTPROXY_H_ | 508 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_WEBTESTPROXY_H_ |
| OLD | NEW |