Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(939)

Side by Side Diff: android_webview/renderer/aw_content_renderer_client.cc

Issue 325443002: Move about://-related constants from //content to //url (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Android ifx Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | apps/launcher.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 "android_webview/renderer/aw_content_renderer_client.h" 5 #include "android_webview/renderer/aw_content_renderer_client.h"
6 6
7 #include "android_webview/common/aw_resource.h" 7 #include "android_webview/common/aw_resource.h"
8 #include "android_webview/common/render_view_messages.h" 8 #include "android_webview/common/render_view_messages.h"
9 #include "android_webview/common/url_constants.h" 9 #include "android_webview/common/url_constants.h"
10 #include "android_webview/renderer/aw_key_systems.h" 10 #include "android_webview/renderer/aw_key_systems.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 || type == blink::WebNavigationTypeBackForward; 89 || type == blink::WebNavigationTypeBackForward;
90 90
91 // Don't offer application-initiated navigations unless it's a redirect. 91 // Don't offer application-initiated navigations unless it's a redirect.
92 if (application_initiated && !is_redirect) 92 if (application_initiated && !is_redirect)
93 return false; 93 return false;
94 94
95 const GURL& gurl = request.url(); 95 const GURL& gurl = request.url();
96 // For HTTP schemes, only top-level navigations can be overridden. Similarly, 96 // For HTTP schemes, only top-level navigations can be overridden. Similarly,
97 // WebView Classic lets app override only top level about:blank navigations. 97 // WebView Classic lets app override only top level about:blank navigations.
98 // So we filter out non-top about:blank navigations here. 98 // So we filter out non-top about:blank navigations here.
99 if (frame->parent() && (gurl.SchemeIs(url::kHttpScheme) || 99 if (frame->parent() &&
100 gurl.SchemeIs(url::kHttpsScheme) || 100 (gurl.SchemeIs(url::kHttpScheme) || gurl.SchemeIs(url::kHttpsScheme) ||
101 gurl.SchemeIs(content::kAboutScheme))) 101 gurl.SchemeIs(url::kAboutScheme)))
102 return false; 102 return false;
103 103
104 // use NavigationInterception throttle to handle the call as that can 104 // use NavigationInterception throttle to handle the call as that can
105 // be deferred until after the java side has been constructed. 105 // be deferred until after the java side has been constructed.
106 if (opener_id != MSG_ROUTING_NONE) { 106 if (opener_id != MSG_ROUTING_NONE) {
107 return false; 107 return false;
108 } 108 }
109 109
110 bool ignore_navigation = false; 110 bool ignore_navigation = false;
111 base::string16 url = request.url().string(); 111 base::string16 url = request.url().string();
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 bool AwContentRendererClient::IsLinkVisited(unsigned long long link_hash) { 193 bool AwContentRendererClient::IsLinkVisited(unsigned long long link_hash) {
194 return visited_link_slave_->IsVisited(link_hash); 194 return visited_link_slave_->IsVisited(link_hash);
195 } 195 }
196 196
197 void AwContentRendererClient::AddKeySystems( 197 void AwContentRendererClient::AddKeySystems(
198 std::vector<content::KeySystemInfo>* key_systems) { 198 std::vector<content::KeySystemInfo>* key_systems) {
199 AwAddKeySystems(key_systems); 199 AwAddKeySystems(key_systems);
200 } 200 }
201 201
202 } // namespace android_webview 202 } // namespace android_webview
OLDNEW
« no previous file with comments | « no previous file | apps/launcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698