| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/browser/frame_host/render_frame_host_impl.h" | 5 #include "content/browser/frame_host/render_frame_host_impl.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/containers/hash_tables.h" | 9 #include "base/containers/hash_tables.h" |
| 10 #include "base/lazy_instance.h" | 10 #include "base/lazy_instance.h" |
| (...skipping 1691 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1702 // | 1702 // |
| 1703 // Blink doesn't send throb notifications for JavaScript URLs, so it is not | 1703 // Blink doesn't send throb notifications for JavaScript URLs, so it is not |
| 1704 // done here either. | 1704 // done here either. |
| 1705 if (!common_params.url.SchemeIs(url::kJavaScriptScheme)) | 1705 if (!common_params.url.SchemeIs(url::kJavaScriptScheme)) |
| 1706 frame_tree_node_->DidStartLoading(true); | 1706 frame_tree_node_->DidStartLoading(true); |
| 1707 } | 1707 } |
| 1708 | 1708 |
| 1709 void RenderFrameHostImpl::NavigateToURL(const GURL& url) { | 1709 void RenderFrameHostImpl::NavigateToURL(const GURL& url) { |
| 1710 CommonNavigationParams common_params( | 1710 CommonNavigationParams common_params( |
| 1711 url, Referrer(), ui::PAGE_TRANSITION_LINK, FrameMsg_Navigate_Type::NORMAL, | 1711 url, Referrer(), ui::PAGE_TRANSITION_LINK, FrameMsg_Navigate_Type::NORMAL, |
| 1712 true, base::TimeTicks::Now(), FrameMsg_UILoadMetricsReportType::NO_REPORT, | 1712 true, false, base::TimeTicks::Now(), |
| 1713 GURL(), GURL()); | 1713 FrameMsg_UILoadMetricsReportType::NO_REPORT, GURL(), GURL()); |
| 1714 Navigate(common_params, StartNavigationParams(), RequestNavigationParams()); | 1714 Navigate(common_params, StartNavigationParams(), RequestNavigationParams()); |
| 1715 } | 1715 } |
| 1716 | 1716 |
| 1717 void RenderFrameHostImpl::OpenURL(const FrameHostMsg_OpenURL_Params& params, | 1717 void RenderFrameHostImpl::OpenURL(const FrameHostMsg_OpenURL_Params& params, |
| 1718 SiteInstance* source_site_instance) { | 1718 SiteInstance* source_site_instance) { |
| 1719 GURL validated_url(params.url); | 1719 GURL validated_url(params.url); |
| 1720 GetProcess()->FilterURL(false, &validated_url); | 1720 GetProcess()->FilterURL(false, &validated_url); |
| 1721 | 1721 |
| 1722 TRACE_EVENT1("navigation", "RenderFrameHostImpl::OpenURL", "url", | 1722 TRACE_EVENT1("navigation", "RenderFrameHostImpl::OpenURL", "url", |
| 1723 validated_url.possibly_invalid_spec()); | 1723 validated_url.possibly_invalid_spec()); |
| (...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2169 ChildProcessSecurityPolicyImpl::GetInstance()->HasWebUIBindings( | 2169 ChildProcessSecurityPolicyImpl::GetInstance()->HasWebUIBindings( |
| 2170 GetProcess()->GetID()) || | 2170 GetProcess()->GetID()) || |
| 2171 // It's possible to load about:blank in a Web UI renderer. | 2171 // It's possible to load about:blank in a Web UI renderer. |
| 2172 // See http://crbug.com/42547 | 2172 // See http://crbug.com/42547 |
| 2173 (frame_tree_node_->current_url().spec() == url::kAboutBlankURL) || | 2173 (frame_tree_node_->current_url().spec() == url::kAboutBlankURL) || |
| 2174 // InterstitialPageImpl should be the only case matching this. | 2174 // InterstitialPageImpl should be the only case matching this. |
| 2175 (delegate_->GetAsWebContents() == nullptr); | 2175 (delegate_->GetAsWebContents() == nullptr); |
| 2176 } | 2176 } |
| 2177 | 2177 |
| 2178 } // namespace content | 2178 } // namespace content |
| OLD | NEW |