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 #include "content/shell/webkit_test_runner.h" | 5 #include "content/shell/webkit_test_runner.h" |
6 | 6 |
7 #include <cmath> | 7 #include <cmath> |
8 | 8 |
9 #include "base/base64.h" | 9 #include "base/base64.h" |
10 #include "base/debug/debugger.h" | 10 #include "base/debug/debugger.h" |
(...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
439 | 439 |
440 int WebKitTestRunner::navigationEntryCount() { | 440 int WebKitTestRunner::navigationEntryCount() { |
441 return 0; | 441 return 0; |
442 } | 442 } |
443 | 443 |
444 int WebKitTestRunner::windowCount() { | 444 int WebKitTestRunner::windowCount() { |
445 return window_count_; | 445 return window_count_; |
446 } | 446 } |
447 | 447 |
448 void WebKitTestRunner::goToOffset(int offset) { | 448 void WebKitTestRunner::goToOffset(int offset) { |
449 Send(new ShellViewHostMsg_NotImplemented( | 449 Send(new ShellViewHostMsg_GoToOffset(routing_id(), offset)); |
450 routing_id(), "WebKitTestRunner", "goToOffset")); | |
451 } | 450 } |
452 | 451 |
453 void WebKitTestRunner::reload() { | 452 void WebKitTestRunner::reload() { |
454 Send(new ShellViewHostMsg_NotImplemented( | 453 Send(new ShellViewHostMsg_Reload(routing_id())); |
455 routing_id(), "WebKitTestRunner", "reload")); | |
456 } | 454 } |
457 | 455 |
458 void WebKitTestRunner::loadURLForFrame(const WebURL& url, | 456 void WebKitTestRunner::loadURLForFrame(const WebURL& url, |
459 const std::string& frame_name) { | 457 const std::string& frame_name) { |
460 Send(new ShellViewHostMsg_NotImplemented( | 458 Send(new ShellViewHostMsg_LoadURLForFrame( |
461 routing_id(), "WebKitTestRunner", "loadURLForFrame")); | 459 routing_id(), url, frame_name)); |
462 } | 460 } |
463 | 461 |
464 bool WebKitTestRunner::allowExternalPages() { | 462 bool WebKitTestRunner::allowExternalPages() { |
465 return allow_external_pages_; | 463 return allow_external_pages_; |
466 } | 464 } |
467 | 465 |
468 void WebKitTestRunner::captureHistoryForWindow( | 466 void WebKitTestRunner::captureHistoryForWindow( |
469 size_t windowIndex, | 467 size_t windowIndex, |
470 WebVector<WebKit::WebHistoryItem>* history, | 468 WebVector<WebKit::WebHistoryItem>* history, |
471 size_t* currentEntryIndex) { | 469 size_t* currentEntryIndex) { |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
559 expected_pixel_hash_ = params.expected_pixel_hash; | 557 expected_pixel_hash_ = params.expected_pixel_hash; |
560 is_main_window_ = true; | 558 is_main_window_ = true; |
561 | 559 |
562 WebTestInterfaces* interfaces = | 560 WebTestInterfaces* interfaces = |
563 ShellRenderProcessObserver::GetInstance()->test_interfaces(); | 561 ShellRenderProcessObserver::GetInstance()->test_interfaces(); |
564 interfaces->setTestIsRunning(true); | 562 interfaces->setTestIsRunning(true); |
565 interfaces->configureForTestWithURL(params.test_url, enable_pixel_dumping_); | 563 interfaces->configureForTestWithURL(params.test_url, enable_pixel_dumping_); |
566 } | 564 } |
567 | 565 |
568 } // namespace content | 566 } // namespace content |
OLD | NEW |