summaryrefslogtreecommitdiffstats
path: root/webkit/tools/test_shell/test_shell.cc
diff options
context:
space:
mode:
authordarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-10 05:46:45 +0000
committerdarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-10 05:46:45 +0000
commitdd7daa80d25deb78ab365e28df4d93437357793b (patch)
treefb4dd2331820f5e32ddeb7e2bfb731f0604fbc0d /webkit/tools/test_shell/test_shell.cc
parent64c40aa34646a198a04029ee6b78dd9559595dc5 (diff)
downloadchromium_src-dd7daa80d25deb78ab365e28df4d93437357793b.zip
chromium_src-dd7daa80d25deb78ab365e28df4d93437357793b.tar.gz
chromium_src-dd7daa80d25deb78ab365e28df4d93437357793b.tar.bz2
Switch to WebFrame from the WebKit API.
I tried to avoid unnecessary changes in this CL to help make it easier to review. As part of this CL, glue/webtextinput* are folded into WebFrame / WebFrameImpl. R=dglazkov BUG=10034 TEST=none Review URL: http://codereview.chromium.org/164225 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22896 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/tools/test_shell/test_shell.cc')
-rw-r--r--webkit/tools/test_shell/test_shell.cc15
1 files changed, 8 insertions, 7 deletions
diff --git a/webkit/tools/test_shell/test_shell.cc b/webkit/tools/test_shell/test_shell.cc
index 3f9fcde..1d296bf 100644
--- a/webkit/tools/test_shell/test_shell.cc
+++ b/webkit/tools/test_shell/test_shell.cc
@@ -31,15 +31,15 @@
#include "skia/ext/bitmap_platform_device.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/skia/include/core/SkBitmap.h"
-#include "webkit/api/public/WebRect.h"
+#include "webkit/api/public/WebFrame.h"
#include "webkit/api/public/WebKit.h"
+#include "webkit/api/public/WebRect.h"
#include "webkit/api/public/WebSize.h"
#include "webkit/api/public/WebString.h"
#include "webkit/api/public/WebURL.h"
#include "webkit/api/public/WebURLRequest.h"
#include "webkit/api/public/WebURLResponse.h"
#include "webkit/glue/glue_serialize.h"
-#include "webkit/glue/webframe.h"
#include "webkit/glue/webkit_glue.h"
#include "webkit/glue/webpreferences.h"
#include "webkit/glue/webview.h"
@@ -47,6 +47,7 @@
#include "webkit/tools/test_shell/test_navigation_controller.h"
#include "webkit/tools/test_shell/test_shell_switches.h"
+using WebKit::WebFrame;
using WebKit::WebNavigationPolicy;
using WebKit::WebRect;
using WebKit::WebSize;
@@ -201,7 +202,7 @@ void TestShell::Dump(TestShell* shell) {
if (!should_dump_as_text) {
// Plain text pages should be dumped as text
const string16& mime_type =
- frame->GetDataSource()->response().mimeType();
+ frame->dataSource()->response().mimeType();
should_dump_as_text = EqualsASCII(mime_type, "text/plain");
}
if (should_dump_as_text) {
@@ -474,7 +475,7 @@ void TestShell::DumpBackForwardList(std::wstring* result) {
}
void TestShell::CallJSGC() {
- webView()->GetMainFrame()->CallJSGC();
+ webView()->GetMainFrame()->collectGarbage();
}
WebView* TestShell::CreateWebView(WebView* webview) {
@@ -530,14 +531,14 @@ bool TestShell::Navigate(const TestNavigationEntry& entry, bool reload) {
// If we are reloading, then WebKit will use the state of the current page.
// Otherwise, we give it the state to navigate to.
if (reload) {
- frame->Reload();
+ frame->reload();
} else if (!entry.GetContentState().empty()) {
DCHECK(entry.GetPageID() != -1);
- frame->LoadHistoryItem(
+ frame->loadHistoryItem(
webkit_glue::HistoryItemFromString(entry.GetContentState()));
} else {
DCHECK(entry.GetPageID() == -1);
- frame->LoadRequest(WebURLRequest(entry.GetURL()));
+ frame->loadRequest(WebURLRequest(entry.GetURL()));
}
// In case LoadRequest failed before DidCreateDataSource was called.