summaryrefslogtreecommitdiffstats
path: root/webkit/tools
diff options
context:
space:
mode:
authorjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-19 15:28:11 +0000
committerjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-19 15:28:11 +0000
commitf4f40a05cea2c55011677d70bf0cada2fa876017 (patch)
tree2b8055f0ae3ab85ed2aa374a65610edc02bdbe26 /webkit/tools
parente3b5940c87035d212b1e59605e2a7d5972484fa3 (diff)
downloadchromium_src-f4f40a05cea2c55011677d70bf0cada2fa876017.zip
chromium_src-f4f40a05cea2c55011677d70bf0cada2fa876017.tar.gz
chromium_src-f4f40a05cea2c55011677d70bf0cada2fa876017.tar.bz2
Remove WebNode parameter from decidePolicyForNavigation
This prepares for removing the WebNode originating_node parameter from WebFrameLoader::decidePolicyForNavigation() by adding overrides that don't use the parameter. After Blink moves over to calling the node-less version of these functions and is rolled into Chromium, the WebNode overrides can be deleted. Review URL: https://chromiumcodereview.appspot.com/14330009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@195211 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/tools')
-rw-r--r--webkit/tools/test_shell/test_webview_delegate.cc19
-rw-r--r--webkit/tools/test_shell/test_webview_delegate.h5
2 files changed, 16 insertions, 8 deletions
diff --git a/webkit/tools/test_shell/test_webview_delegate.cc b/webkit/tools/test_shell/test_webview_delegate.cc
index 76945f3..f30b1a8 100644
--- a/webkit/tools/test_shell/test_webview_delegate.cc
+++ b/webkit/tools/test_shell/test_webview_delegate.cc
@@ -558,18 +558,13 @@ void TestWebViewDelegate::loadURLExternally(
WebNavigationPolicy TestWebViewDelegate::decidePolicyForNavigation(
WebFrame* frame, const WebURLRequest& request,
- WebNavigationType type, const WebNode& originating_node,
- WebNavigationPolicy default_policy, bool is_redirect) {
+ WebNavigationType type, WebNavigationPolicy default_policy,
+ bool is_redirect) {
WebNavigationPolicy result;
if (policy_delegate_enabled_) {
- printf("Policy delegate: attempt to load %s with navigation type '%s'",
+ printf("Policy delegate: attempt to load %s with navigation type '%s'\n",
GetURLDescription(request.url()).c_str(),
WebNavigationTypeToString(type));
- if (!originating_node.isNull()) {
- printf(" originating from %s",
- GetNodeDescription(originating_node, 0).c_str());
- }
- printf("\n");
if (policy_delegate_is_permissive_) {
result = WebKit::WebNavigationPolicyCurrentTab;
} else {
@@ -581,6 +576,14 @@ WebNavigationPolicy TestWebViewDelegate::decidePolicyForNavigation(
return result;
}
+WebNavigationPolicy TestWebViewDelegate::decidePolicyForNavigation(
+ WebFrame* frame, const WebURLRequest& request,
+ WebNavigationType type, const WebNode& originating_node,
+ WebNavigationPolicy default_policy, bool is_redirect) {
+ return decidePolicyForNavigation(frame, request, type,
+ default_policy, is_redirect);
+}
+
bool TestWebViewDelegate::canHandleRequest(
WebFrame* frame, const WebURLRequest& request) {
GURL url = request.url();
diff --git a/webkit/tools/test_shell/test_webview_delegate.h b/webkit/tools/test_shell/test_webview_delegate.h
index 8d1e5fc..9e143e2 100644
--- a/webkit/tools/test_shell/test_webview_delegate.h
+++ b/webkit/tools/test_shell/test_webview_delegate.h
@@ -175,6 +175,11 @@ class TestWebViewDelegate : public WebKit::WebViewClient,
WebKit::WebNavigationPolicy);
virtual WebKit::WebNavigationPolicy decidePolicyForNavigation(
WebKit::WebFrame*, const WebKit::WebURLRequest&,
+ WebKit::WebNavigationType, WebKit::WebNavigationPolicy default_policy,
+ bool isRedirect);
+ // DEPRECATED
+ virtual WebKit::WebNavigationPolicy decidePolicyForNavigation(
+ WebKit::WebFrame*, const WebKit::WebURLRequest&,
WebKit::WebNavigationType, const WebKit::WebNode&,
WebKit::WebNavigationPolicy default_policy, bool isRedirect);
virtual bool canHandleRequest(