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 <stddef.h> |
| 8 |
7 #include <utility> | 9 #include <utility> |
8 | 10 |
9 #include "base/command_line.h" | 11 #include "base/command_line.h" |
10 #include "base/lazy_instance.h" | 12 #include "base/lazy_instance.h" |
11 #include "base/location.h" | 13 #include "base/location.h" |
12 #include "base/logging.h" | 14 #include "base/logging.h" |
| 15 #include "base/macros.h" |
13 #include "base/metrics/histogram.h" | 16 #include "base/metrics/histogram.h" |
14 #include "base/process/process.h" | 17 #include "base/process/process.h" |
15 #include "base/profiler/scoped_tracker.h" | 18 #include "base/profiler/scoped_tracker.h" |
16 #include "base/single_thread_task_runner.h" | 19 #include "base/single_thread_task_runner.h" |
17 #include "base/strings/string16.h" | 20 #include "base/strings/string16.h" |
18 #include "base/strings/string_number_conversions.h" | 21 #include "base/strings/string_number_conversions.h" |
19 #include "base/strings/string_util.h" | 22 #include "base/strings/string_util.h" |
20 #include "base/strings/utf_string_conversions.h" | 23 #include "base/strings/utf_string_conversions.h" |
21 #include "base/thread_task_runner_handle.h" | 24 #include "base/thread_task_runner_handle.h" |
22 #include "base/time/time.h" | 25 #include "base/time/time.h" |
23 #include "base/trace_event/trace_event.h" | 26 #include "base/trace_event/trace_event.h" |
| 27 #include "build/build_config.h" |
24 #include "components/mime_util/mime_util.h" | 28 #include "components/mime_util/mime_util.h" |
25 #include "components/url_formatter/url_formatter.h" | 29 #include "components/url_formatter/url_formatter.h" |
26 #include "content/browser/accessibility/accessibility_mode_helper.h" | 30 #include "content/browser/accessibility/accessibility_mode_helper.h" |
27 #include "content/browser/accessibility/browser_accessibility_state_impl.h" | 31 #include "content/browser/accessibility/browser_accessibility_state_impl.h" |
28 #include "content/browser/bad_message.h" | 32 #include "content/browser/bad_message.h" |
29 #include "content/browser/browser_plugin/browser_plugin_embedder.h" | 33 #include "content/browser/browser_plugin/browser_plugin_embedder.h" |
30 #include "content/browser/browser_plugin/browser_plugin_guest.h" | 34 #include "content/browser/browser_plugin/browser_plugin_guest.h" |
31 #include "content/browser/child_process_security_policy_impl.h" | 35 #include "content/browser/child_process_security_policy_impl.h" |
32 #include "content/browser/dom_storage/dom_storage_context_wrapper.h" | 36 #include "content/browser/dom_storage/dom_storage_context_wrapper.h" |
33 #include "content/browser/dom_storage/session_storage_namespace_impl.h" | 37 #include "content/browser/dom_storage/session_storage_namespace_impl.h" |
(...skipping 937 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
971 | 975 |
972 if (entry) { | 976 if (entry) { |
973 return entry->GetTitleForDisplay(accept_languages); | 977 return entry->GetTitleForDisplay(accept_languages); |
974 } | 978 } |
975 | 979 |
976 // |page_title_when_no_navigation_entry_| is finally used | 980 // |page_title_when_no_navigation_entry_| is finally used |
977 // if no title cannot be retrieved. | 981 // if no title cannot be retrieved. |
978 return page_title_when_no_navigation_entry_; | 982 return page_title_when_no_navigation_entry_; |
979 } | 983 } |
980 | 984 |
981 int32 WebContentsImpl::GetMaxPageID() { | 985 int32_t WebContentsImpl::GetMaxPageID() { |
982 return GetMaxPageIDForSiteInstance(GetSiteInstance()); | 986 return GetMaxPageIDForSiteInstance(GetSiteInstance()); |
983 } | 987 } |
984 | 988 |
985 int32 WebContentsImpl::GetMaxPageIDForSiteInstance( | 989 int32_t WebContentsImpl::GetMaxPageIDForSiteInstance( |
986 SiteInstance* site_instance) { | 990 SiteInstance* site_instance) { |
987 if (max_page_ids_.find(site_instance->GetId()) == max_page_ids_.end()) | 991 if (max_page_ids_.find(site_instance->GetId()) == max_page_ids_.end()) |
988 max_page_ids_[site_instance->GetId()] = -1; | 992 max_page_ids_[site_instance->GetId()] = -1; |
989 | 993 |
990 return max_page_ids_[site_instance->GetId()]; | 994 return max_page_ids_[site_instance->GetId()]; |
991 } | 995 } |
992 | 996 |
993 void WebContentsImpl::UpdateMaxPageID(int32 page_id) { | 997 void WebContentsImpl::UpdateMaxPageID(int32_t page_id) { |
994 UpdateMaxPageIDForSiteInstance(GetSiteInstance(), page_id); | 998 UpdateMaxPageIDForSiteInstance(GetSiteInstance(), page_id); |
995 } | 999 } |
996 | 1000 |
997 void WebContentsImpl::UpdateMaxPageIDForSiteInstance( | 1001 void WebContentsImpl::UpdateMaxPageIDForSiteInstance( |
998 SiteInstance* site_instance, int32 page_id) { | 1002 SiteInstance* site_instance, |
| 1003 int32_t page_id) { |
999 if (GetMaxPageIDForSiteInstance(site_instance) < page_id) | 1004 if (GetMaxPageIDForSiteInstance(site_instance) < page_id) |
1000 max_page_ids_[site_instance->GetId()] = page_id; | 1005 max_page_ids_[site_instance->GetId()] = page_id; |
1001 } | 1006 } |
1002 | 1007 |
1003 void WebContentsImpl::CopyMaxPageIDsFrom(WebContents* web_contents) { | 1008 void WebContentsImpl::CopyMaxPageIDsFrom(WebContents* web_contents) { |
1004 WebContentsImpl* contents = static_cast<WebContentsImpl*>(web_contents); | 1009 WebContentsImpl* contents = static_cast<WebContentsImpl*>(web_contents); |
1005 max_page_ids_ = contents->max_page_ids_; | 1010 max_page_ids_ = contents->max_page_ids_; |
1006 } | 1011 } |
1007 | 1012 |
1008 SiteInstanceImpl* WebContentsImpl::GetSiteInstance() const { | 1013 SiteInstanceImpl* WebContentsImpl::GetSiteInstance() const { |
(...skipping 21 matching lines...) Expand all Loading... |
1030 } | 1035 } |
1031 | 1036 |
1032 const net::LoadStateWithParam& WebContentsImpl::GetLoadState() const { | 1037 const net::LoadStateWithParam& WebContentsImpl::GetLoadState() const { |
1033 return load_state_; | 1038 return load_state_; |
1034 } | 1039 } |
1035 | 1040 |
1036 const base::string16& WebContentsImpl::GetLoadStateHost() const { | 1041 const base::string16& WebContentsImpl::GetLoadStateHost() const { |
1037 return load_state_host_; | 1042 return load_state_host_; |
1038 } | 1043 } |
1039 | 1044 |
1040 uint64 WebContentsImpl::GetUploadSize() const { | 1045 uint64_t WebContentsImpl::GetUploadSize() const { |
1041 return upload_size_; | 1046 return upload_size_; |
1042 } | 1047 } |
1043 | 1048 |
1044 uint64 WebContentsImpl::GetUploadPosition() const { | 1049 uint64_t WebContentsImpl::GetUploadPosition() const { |
1045 return upload_position_; | 1050 return upload_position_; |
1046 } | 1051 } |
1047 | 1052 |
1048 const std::string& WebContentsImpl::GetEncoding() const { | 1053 const std::string& WebContentsImpl::GetEncoding() const { |
1049 return canonical_encoding_; | 1054 return canonical_encoding_; |
1050 } | 1055 } |
1051 | 1056 |
1052 bool WebContentsImpl::DisplayedInsecureContent() const { | 1057 bool WebContentsImpl::DisplayedInsecureContent() const { |
1053 return displayed_insecure_content_; | 1058 return displayed_insecure_content_; |
1054 } | 1059 } |
(...skipping 843 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1898 // We are in asynchronous add new contents path, delay opening url | 1903 // We are in asynchronous add new contents path, delay opening url |
1899 new_contents->delayed_open_url_params_.reset( | 1904 new_contents->delayed_open_url_params_.reset( |
1900 new OpenURLParams(open_params)); | 1905 new OpenURLParams(open_params)); |
1901 } else { | 1906 } else { |
1902 new_contents->OpenURL(open_params); | 1907 new_contents->OpenURL(open_params); |
1903 } | 1908 } |
1904 } | 1909 } |
1905 } | 1910 } |
1906 } | 1911 } |
1907 | 1912 |
1908 void WebContentsImpl::CreateNewWidget(int32 render_process_id, | 1913 void WebContentsImpl::CreateNewWidget(int32_t render_process_id, |
1909 int32 route_id, | 1914 int32_t route_id, |
1910 blink::WebPopupType popup_type) { | 1915 blink::WebPopupType popup_type) { |
1911 CreateNewWidget(render_process_id, route_id, false, popup_type); | 1916 CreateNewWidget(render_process_id, route_id, false, popup_type); |
1912 } | 1917 } |
1913 | 1918 |
1914 void WebContentsImpl::CreateNewFullscreenWidget(int32 render_process_id, | 1919 void WebContentsImpl::CreateNewFullscreenWidget(int32_t render_process_id, |
1915 int32 route_id) { | 1920 int32_t route_id) { |
1916 CreateNewWidget(render_process_id, route_id, true, blink::WebPopupTypeNone); | 1921 CreateNewWidget(render_process_id, route_id, true, blink::WebPopupTypeNone); |
1917 } | 1922 } |
1918 | 1923 |
1919 void WebContentsImpl::CreateNewWidget(int32 render_process_id, | 1924 void WebContentsImpl::CreateNewWidget(int32_t render_process_id, |
1920 int32 route_id, | 1925 int32_t route_id, |
1921 bool is_fullscreen, | 1926 bool is_fullscreen, |
1922 blink::WebPopupType popup_type) { | 1927 blink::WebPopupType popup_type) { |
1923 RenderProcessHost* process = GetRenderProcessHost(); | 1928 RenderProcessHost* process = GetRenderProcessHost(); |
1924 // A message to create a new widget can only come from an active process for | 1929 // A message to create a new widget can only come from an active process for |
1925 // this WebContentsImpl instance. If any other process sends the request, | 1930 // this WebContentsImpl instance. If any other process sends the request, |
1926 // it is invalid and the process must be terminated. | 1931 // it is invalid and the process must be terminated. |
1927 bool did_match_process = false; | 1932 bool did_match_process = false; |
1928 frame_tree_.ForEach( | 1933 frame_tree_.ForEach( |
1929 base::Bind(&FindMatchingProcess, render_process_id, &did_match_process)); | 1934 base::Bind(&FindMatchingProcess, render_process_id, &did_match_process)); |
1930 if (!did_match_process) { | 1935 if (!did_match_process) { |
(...skipping 623 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2554 return; | 2559 return; |
2555 | 2560 |
2556 // TODO(nasko): This check for main frame is incorrect and should be fixed | 2561 // TODO(nasko): This check for main frame is incorrect and should be fixed |
2557 // by explicitly passing in which frame this method should target. | 2562 // by explicitly passing in which frame this method should target. |
2558 bool is_main_frame = (url == GetLastCommittedURL()); | 2563 bool is_main_frame = (url == GetLastCommittedURL()); |
2559 | 2564 |
2560 DownloadManager* dlm = | 2565 DownloadManager* dlm = |
2561 BrowserContext::GetDownloadManager(GetBrowserContext()); | 2566 BrowserContext::GetDownloadManager(GetBrowserContext()); |
2562 if (!dlm) | 2567 if (!dlm) |
2563 return; | 2568 return; |
2564 int64 post_id = -1; | 2569 int64_t post_id = -1; |
2565 if (is_main_frame) { | 2570 if (is_main_frame) { |
2566 const NavigationEntry* entry = controller_.GetLastCommittedEntry(); | 2571 const NavigationEntry* entry = controller_.GetLastCommittedEntry(); |
2567 if (entry) | 2572 if (entry) |
2568 post_id = entry->GetPostID(); | 2573 post_id = entry->GetPostID(); |
2569 } | 2574 } |
2570 scoped_ptr<DownloadUrlParameters> params( | 2575 scoped_ptr<DownloadUrlParameters> params( |
2571 DownloadUrlParameters::FromWebContents(this, url)); | 2576 DownloadUrlParameters::FromWebContents(this, url)); |
2572 params->set_referrer(referrer); | 2577 params->set_referrer(referrer); |
2573 params->set_post_id(post_id); | 2578 params->set_post_id(post_id); |
2574 if (post_id >= 0) | 2579 if (post_id >= 0) |
(...skipping 10 matching lines...) Expand all Loading... |
2585 key_value, ":", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); | 2590 key_value, ":", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); |
2586 DCHECK_EQ(2ul, pair.size()); | 2591 DCHECK_EQ(2ul, pair.size()); |
2587 params->add_request_header(pair[0], pair[1]); | 2592 params->add_request_header(pair[0], pair[1]); |
2588 } | 2593 } |
2589 } | 2594 } |
2590 dlm->DownloadUrl(params.Pass()); | 2595 dlm->DownloadUrl(params.Pass()); |
2591 } | 2596 } |
2592 | 2597 |
2593 void WebContentsImpl::GenerateMHTML( | 2598 void WebContentsImpl::GenerateMHTML( |
2594 const base::FilePath& file, | 2599 const base::FilePath& file, |
2595 const base::Callback<void(int64)>& callback) { | 2600 const base::Callback<void(int64_t)>& callback) { |
2596 MHTMLGenerationManager::GetInstance()->SaveMHTML(this, file, callback); | 2601 MHTMLGenerationManager::GetInstance()->SaveMHTML(this, file, callback); |
2597 } | 2602 } |
2598 | 2603 |
2599 const std::string& WebContentsImpl::GetContentsMimeType() const { | 2604 const std::string& WebContentsImpl::GetContentsMimeType() const { |
2600 return contents_mime_type_; | 2605 return contents_mime_type_; |
2601 } | 2606 } |
2602 | 2607 |
2603 bool WebContentsImpl::WillNotifyDisconnection() const { | 2608 bool WebContentsImpl::WillNotifyDisconnection() const { |
2604 return notify_disconnection_; | 2609 return notify_disconnection_; |
2605 } | 2610 } |
(...skipping 1327 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3933 FOR_EACH_OBSERVER(WebContentsObserver, | 3938 FOR_EACH_OBSERVER(WebContentsObserver, |
3934 observers_, | 3939 observers_, |
3935 RenderProcessGone(GetCrashedStatus())); | 3940 RenderProcessGone(GetCrashedStatus())); |
3936 } | 3941 } |
3937 | 3942 |
3938 void WebContentsImpl::RenderViewDeleted(RenderViewHost* rvh) { | 3943 void WebContentsImpl::RenderViewDeleted(RenderViewHost* rvh) { |
3939 FOR_EACH_OBSERVER(WebContentsObserver, observers_, RenderViewDeleted(rvh)); | 3944 FOR_EACH_OBSERVER(WebContentsObserver, observers_, RenderViewDeleted(rvh)); |
3940 } | 3945 } |
3941 | 3946 |
3942 void WebContentsImpl::UpdateState(RenderViewHost* rvh, | 3947 void WebContentsImpl::UpdateState(RenderViewHost* rvh, |
3943 int32 page_id, | 3948 int32_t page_id, |
3944 const PageState& page_state) { | 3949 const PageState& page_state) { |
3945 DCHECK(!SiteIsolationPolicy::UseSubframeNavigationEntries()); | 3950 DCHECK(!SiteIsolationPolicy::UseSubframeNavigationEntries()); |
3946 | 3951 |
3947 // Ensure that this state update comes from a RenderViewHost that belongs to | 3952 // Ensure that this state update comes from a RenderViewHost that belongs to |
3948 // this WebContents. | 3953 // this WebContents. |
3949 // TODO(nasko): This should go through RenderFrameHost. | 3954 // TODO(nasko): This should go through RenderFrameHost. |
3950 if (rvh->GetDelegate()->GetAsWebContents() != this) | 3955 if (rvh->GetDelegate()->GetAsWebContents() != this) |
3951 return; | 3956 return; |
3952 | 3957 |
3953 // We must be prepared to handle state updates for any page. They occur | 3958 // We must be prepared to handle state updates for any page. They occur |
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4159 return; | 4164 return; |
4160 | 4165 |
4161 if (page_state == frame_entry->page_state()) | 4166 if (page_state == frame_entry->page_state()) |
4162 return; // Nothing to update. | 4167 return; // Nothing to update. |
4163 | 4168 |
4164 frame_entry->set_page_state(page_state); | 4169 frame_entry->set_page_state(page_state); |
4165 controller_.NotifyEntryChanged(entry); | 4170 controller_.NotifyEntryChanged(entry); |
4166 } | 4171 } |
4167 | 4172 |
4168 void WebContentsImpl::UpdateTitle(RenderFrameHost* render_frame_host, | 4173 void WebContentsImpl::UpdateTitle(RenderFrameHost* render_frame_host, |
4169 int32 page_id, | 4174 int32_t page_id, |
4170 const base::string16& title, | 4175 const base::string16& title, |
4171 base::i18n::TextDirection title_direction) { | 4176 base::i18n::TextDirection title_direction) { |
4172 // If we have a title, that's a pretty good indication that we've started | 4177 // If we have a title, that's a pretty good indication that we've started |
4173 // getting useful data. | 4178 // getting useful data. |
4174 SetNotWaitingForResponse(); | 4179 SetNotWaitingForResponse(); |
4175 | 4180 |
4176 // Try to find the navigation entry, which might not be the current one. | 4181 // Try to find the navigation entry, which might not be the current one. |
4177 // For example, it might be from a recently swapped out RFH. | 4182 // For example, it might be from a recently swapped out RFH. |
4178 NavigationEntryImpl* entry = controller_.GetEntryWithPageID( | 4183 NavigationEntryImpl* entry = controller_.GetEntryWithPageID( |
4179 render_frame_host->GetSiteInstance(), page_id); | 4184 render_frame_host->GetSiteInstance(), page_id); |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4256 } | 4261 } |
4257 } else { | 4262 } else { |
4258 RenderFrameHostImpl* source_rfhi = | 4263 RenderFrameHostImpl* source_rfhi = |
4259 static_cast<RenderFrameHostImpl*>(source_rfh); | 4264 static_cast<RenderFrameHostImpl*>(source_rfh); |
4260 source_rfhi->frame_tree_node()->render_manager()->CreateOpenerProxies( | 4265 source_rfhi->frame_tree_node()->render_manager()->CreateOpenerProxies( |
4261 GetSiteInstance(), nullptr); | 4266 GetSiteInstance(), nullptr); |
4262 } | 4267 } |
4263 } | 4268 } |
4264 } | 4269 } |
4265 | 4270 |
4266 bool WebContentsImpl::AddMessageToConsole(int32 level, | 4271 bool WebContentsImpl::AddMessageToConsole(int32_t level, |
4267 const base::string16& message, | 4272 const base::string16& message, |
4268 int32 line_no, | 4273 int32_t line_no, |
4269 const base::string16& source_id) { | 4274 const base::string16& source_id) { |
4270 if (!delegate_) | 4275 if (!delegate_) |
4271 return false; | 4276 return false; |
4272 return delegate_->AddMessageToConsole(this, level, message, line_no, | 4277 return delegate_->AddMessageToConsole(this, level, message, line_no, |
4273 source_id); | 4278 source_id); |
4274 } | 4279 } |
4275 | 4280 |
4276 int WebContentsImpl::CreateSwappedOutRenderView( | 4281 int WebContentsImpl::CreateSwappedOutRenderView( |
4277 SiteInstance* instance) { | 4282 SiteInstance* instance) { |
4278 int render_view_routing_id = MSG_ROUTING_NONE; | 4283 int render_view_routing_id = MSG_ROUTING_NONE; |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4359 if (render_widget_host != GetRenderViewHost()->GetWidget()) | 4364 if (render_widget_host != GetRenderViewHost()->GetWidget()) |
4360 return; | 4365 return; |
4361 | 4366 |
4362 if (delegate_) | 4367 if (delegate_) |
4363 delegate_->RendererResponsive(this); | 4368 delegate_->RendererResponsive(this); |
4364 } | 4369 } |
4365 | 4370 |
4366 void WebContentsImpl::LoadStateChanged( | 4371 void WebContentsImpl::LoadStateChanged( |
4367 const GURL& url, | 4372 const GURL& url, |
4368 const net::LoadStateWithParam& load_state, | 4373 const net::LoadStateWithParam& load_state, |
4369 uint64 upload_position, | 4374 uint64_t upload_position, |
4370 uint64 upload_size) { | 4375 uint64_t upload_size) { |
4371 // TODO(erikchen): Remove ScopedTracker below once http://crbug.com/466285 | 4376 // TODO(erikchen): Remove ScopedTracker below once http://crbug.com/466285 |
4372 // is fixed. | 4377 // is fixed. |
4373 tracked_objects::ScopedTracker tracking_profile1( | 4378 tracked_objects::ScopedTracker tracking_profile1( |
4374 FROM_HERE_WITH_EXPLICIT_FUNCTION( | 4379 FROM_HERE_WITH_EXPLICIT_FUNCTION( |
4375 "466285 WebContentsImpl::LoadStateChanged::Start")); | 4380 "466285 WebContentsImpl::LoadStateChanged::Start")); |
4376 load_state_ = load_state; | 4381 load_state_ = load_state; |
4377 upload_position_ = upload_position; | 4382 upload_position_ = upload_position; |
4378 upload_size_ = upload_size; | 4383 upload_size_ = upload_size; |
4379 load_state_host_ = url_formatter::IDNToUnicode( | 4384 load_state_host_ = url_formatter::IDNToUnicode( |
4380 url.host(), | 4385 url.host(), |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4490 int proxy_routing_id, | 4495 int proxy_routing_id, |
4491 const FrameReplicationState& replicated_frame_state) { | 4496 const FrameReplicationState& replicated_frame_state) { |
4492 TRACE_EVENT0("browser,navigation", | 4497 TRACE_EVENT0("browser,navigation", |
4493 "WebContentsImpl::CreateRenderViewForRenderManager"); | 4498 "WebContentsImpl::CreateRenderViewForRenderManager"); |
4494 | 4499 |
4495 if (proxy_routing_id == MSG_ROUTING_NONE) | 4500 if (proxy_routing_id == MSG_ROUTING_NONE) |
4496 CreateRenderWidgetHostViewForRenderManager(render_view_host); | 4501 CreateRenderWidgetHostViewForRenderManager(render_view_host); |
4497 | 4502 |
4498 // Make sure we use the correct starting page_id in the new RenderView. | 4503 // Make sure we use the correct starting page_id in the new RenderView. |
4499 UpdateMaxPageIDIfNecessary(render_view_host); | 4504 UpdateMaxPageIDIfNecessary(render_view_host); |
4500 int32 max_page_id = | 4505 int32_t max_page_id = |
4501 GetMaxPageIDForSiteInstance(render_view_host->GetSiteInstance()); | 4506 GetMaxPageIDForSiteInstance(render_view_host->GetSiteInstance()); |
4502 | 4507 |
4503 if (!static_cast<RenderViewHostImpl*>(render_view_host) | 4508 if (!static_cast<RenderViewHostImpl*>(render_view_host) |
4504 ->CreateRenderView(opener_frame_routing_id, proxy_routing_id, | 4509 ->CreateRenderView(opener_frame_routing_id, proxy_routing_id, |
4505 max_page_id, replicated_frame_state, | 4510 max_page_id, replicated_frame_state, |
4506 created_with_opener_)) { | 4511 created_with_opener_)) { |
4507 return false; | 4512 return false; |
4508 } | 4513 } |
4509 | 4514 |
4510 SetHistoryOffsetAndLengthForView(render_view_host, | 4515 SetHistoryOffsetAndLengthForView(render_view_host, |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4715 const WebContentsObserver::MediaPlayerId& id) { | 4720 const WebContentsObserver::MediaPlayerId& id) { |
4716 FOR_EACH_OBSERVER(WebContentsObserver, observers_, MediaStartedPlaying(id)); | 4721 FOR_EACH_OBSERVER(WebContentsObserver, observers_, MediaStartedPlaying(id)); |
4717 } | 4722 } |
4718 | 4723 |
4719 void WebContentsImpl::MediaStoppedPlaying( | 4724 void WebContentsImpl::MediaStoppedPlaying( |
4720 const WebContentsObserver::MediaPlayerId& id) { | 4725 const WebContentsObserver::MediaPlayerId& id) { |
4721 FOR_EACH_OBSERVER(WebContentsObserver, observers_, MediaStoppedPlaying(id)); | 4726 FOR_EACH_OBSERVER(WebContentsObserver, observers_, MediaStoppedPlaying(id)); |
4722 } | 4727 } |
4723 | 4728 |
4724 } // namespace content | 4729 } // namespace content |
OLD | NEW |