OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "content/browser/web_contents/web_contents_impl.h" | 5 #include "content/browser/web_contents/web_contents_impl.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
(...skipping 1960 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1971 delegate_->WebIntentDispatch(this, intents_dispatcher); | 1971 delegate_->WebIntentDispatch(this, intents_dispatcher); |
1972 } | 1972 } |
1973 | 1973 |
1974 void WebContentsImpl::DidStartProvisionalLoadForFrame( | 1974 void WebContentsImpl::DidStartProvisionalLoadForFrame( |
1975 RenderViewHost* render_view_host, | 1975 RenderViewHost* render_view_host, |
1976 int64 frame_id, | 1976 int64 frame_id, |
1977 int64 parent_frame_id, | 1977 int64 parent_frame_id, |
1978 bool is_main_frame, | 1978 bool is_main_frame, |
1979 const GURL& url) { | 1979 const GURL& url) { |
1980 bool is_error_page = (url.spec() == kUnreachableWebDataURL); | 1980 bool is_error_page = (url.spec() == kUnreachableWebDataURL); |
| 1981 bool is_iframe_srcdoc = (url.spec() == chrome::kAboutSrcDocURL); |
1981 GURL validated_url(url); | 1982 GURL validated_url(url); |
1982 RenderProcessHost* render_process_host = | 1983 RenderProcessHost* render_process_host = |
1983 render_view_host->GetProcess(); | 1984 render_view_host->GetProcess(); |
1984 RenderViewHost::FilterURL(render_process_host, false, &validated_url); | 1985 RenderViewHost::FilterURL(render_process_host, false, &validated_url); |
1985 | 1986 |
1986 // Notify observers about the start of the provisional load. | 1987 // Notify observers about the start of the provisional load. |
1987 FOR_EACH_OBSERVER(WebContentsObserver, observers_, | 1988 FOR_EACH_OBSERVER(WebContentsObserver, observers_, |
1988 DidStartProvisionalLoadForFrame(frame_id, parent_frame_id, | 1989 DidStartProvisionalLoadForFrame(frame_id, parent_frame_id, |
1989 is_main_frame, validated_url, is_error_page, | 1990 is_main_frame, validated_url, is_error_page, |
1990 render_view_host)); | 1991 is_iframe_srcdoc, render_view_host)); |
1991 | 1992 |
1992 if (is_main_frame) { | 1993 if (is_main_frame) { |
1993 // Notify observers about the provisional change in the main frame URL. | 1994 // Notify observers about the provisional change in the main frame URL. |
1994 FOR_EACH_OBSERVER(WebContentsObserver, observers_, | 1995 FOR_EACH_OBSERVER(WebContentsObserver, observers_, |
1995 ProvisionalChangeToMainFrameUrl(validated_url, | 1996 ProvisionalChangeToMainFrameUrl(validated_url, |
1996 render_view_host)); | 1997 render_view_host)); |
1997 } | 1998 } |
1998 } | 1999 } |
1999 | 2000 |
2000 void WebContentsImpl::DidRedirectProvisionalLoad( | 2001 void WebContentsImpl::DidRedirectProvisionalLoad( |
(...skipping 1381 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3382 | 3383 |
3383 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { | 3384 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { |
3384 return browser_plugin_guest_.get(); | 3385 return browser_plugin_guest_.get(); |
3385 } | 3386 } |
3386 | 3387 |
3387 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { | 3388 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { |
3388 return browser_plugin_embedder_.get(); | 3389 return browser_plugin_embedder_.get(); |
3389 } | 3390 } |
3390 | 3391 |
3391 } // namespace content | 3392 } // namespace content |
OLD | NEW |