| OLD | NEW |
| 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 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 // Don't offer application-initiated navigations unless it's a redirect. | 90 // Don't offer application-initiated navigations unless it's a redirect. |
| 91 if (application_initiated && !is_redirect) | 91 if (application_initiated && !is_redirect) |
| 92 return false; | 92 return false; |
| 93 | 93 |
| 94 const GURL& gurl = request.url(); | 94 const GURL& gurl = request.url(); |
| 95 // For HTTP schemes, only top-level navigations can be overridden. Similarly, | 95 // For HTTP schemes, only top-level navigations can be overridden. Similarly, |
| 96 // WebView Classic lets app override only top level about:blank navigations. | 96 // WebView Classic lets app override only top level about:blank navigations. |
| 97 // So we filter out non-top about:blank navigations here. | 97 // So we filter out non-top about:blank navigations here. |
| 98 if (frame->parent() && (gurl.SchemeIs(content::kHttpScheme) || | 98 if (frame->parent() && (gurl.SchemeIs(content::kHttpScheme) || |
| 99 gurl.SchemeIs(content::kHttpsScheme) || | 99 gurl.SchemeIs(content::kHttpsScheme) || |
| 100 gurl.SchemeIs(chrome::kAboutScheme))) | 100 gurl.SchemeIs(content::kAboutScheme))) |
| 101 return false; | 101 return false; |
| 102 | 102 |
| 103 // use NavigationInterception throttle to handle the call as that can | 103 // use NavigationInterception throttle to handle the call as that can |
| 104 // be deferred until after the java side has been constructed. | 104 // be deferred until after the java side has been constructed. |
| 105 if (opener_id != MSG_ROUTING_NONE) { | 105 if (opener_id != MSG_ROUTING_NONE) { |
| 106 return false; | 106 return false; |
| 107 } | 107 } |
| 108 | 108 |
| 109 bool ignore_navigation = false; | 109 bool ignore_navigation = false; |
| 110 base::string16 url = request.url().string(); | 110 base::string16 url = request.url().string(); |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 191 bool AwContentRendererClient::IsLinkVisited(unsigned long long link_hash) { | 191 bool AwContentRendererClient::IsLinkVisited(unsigned long long link_hash) { |
| 192 return visited_link_slave_->IsVisited(link_hash); | 192 return visited_link_slave_->IsVisited(link_hash); |
| 193 } | 193 } |
| 194 | 194 |
| 195 void AwContentRendererClient::AddKeySystems( | 195 void AwContentRendererClient::AddKeySystems( |
| 196 std::vector<content::KeySystemInfo>* key_systems) { | 196 std::vector<content::KeySystemInfo>* key_systems) { |
| 197 AwAddKeySystems(key_systems); | 197 AwAddKeySystems(key_systems); |
| 198 } | 198 } |
| 199 | 199 |
| 200 } // namespace android_webview | 200 } // namespace android_webview |
| OLD | NEW |