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_manager.h" | 5 #include "content/browser/frame_host/render_frame_host_manager.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/logging.h" | 10 #include "base/logging.h" |
(...skipping 856 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
867 if (!base::CommandLine::ForCurrentProcess()->HasSwitch( | 867 if (!base::CommandLine::ForCurrentProcess()->HasSwitch( |
868 switches::kSitePerProcess)) | 868 switches::kSitePerProcess)) |
869 return; | 869 return; |
870 | 870 |
871 for (const auto& pair : proxy_hosts_) { | 871 for (const auto& pair : proxy_hosts_) { |
872 pair.second->Send( | 872 pair.second->Send( |
873 new FrameMsg_DidUpdateName(pair.second->GetRoutingID(), name)); | 873 new FrameMsg_DidUpdateName(pair.second->GetRoutingID(), name)); |
874 } | 874 } |
875 } | 875 } |
876 | 876 |
| 877 void RenderFrameHostManager::OnDidUpdateOrigin(const url::Origin& origin) { |
| 878 if (!base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 879 switches::kSitePerProcess)) |
| 880 return; |
| 881 |
| 882 for (const auto& pair : proxy_hosts_) { |
| 883 pair.second->Send( |
| 884 new FrameMsg_DidUpdateOrigin(pair.second->GetRoutingID(), origin)); |
| 885 } |
| 886 } |
| 887 |
877 void RenderFrameHostManager::Observe( | 888 void RenderFrameHostManager::Observe( |
878 int type, | 889 int type, |
879 const NotificationSource& source, | 890 const NotificationSource& source, |
880 const NotificationDetails& details) { | 891 const NotificationDetails& details) { |
881 switch (type) { | 892 switch (type) { |
882 case NOTIFICATION_RENDERER_PROCESS_CLOSED: | 893 case NOTIFICATION_RENDERER_PROCESS_CLOSED: |
883 case NOTIFICATION_RENDERER_PROCESS_CLOSING: | 894 case NOTIFICATION_RENDERER_PROCESS_CLOSING: |
884 RendererProcessClosing( | 895 RendererProcessClosing( |
885 Source<RenderProcessHost>(source).ptr()); | 896 Source<RenderProcessHost>(source).ptr()); |
886 break; | 897 break; |
(...skipping 1194 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2081 void RenderFrameHostManager::DeleteRenderFrameProxyHost( | 2092 void RenderFrameHostManager::DeleteRenderFrameProxyHost( |
2082 SiteInstance* instance) { | 2093 SiteInstance* instance) { |
2083 RenderFrameProxyHostMap::iterator iter = proxy_hosts_.find(instance->GetId()); | 2094 RenderFrameProxyHostMap::iterator iter = proxy_hosts_.find(instance->GetId()); |
2084 if (iter != proxy_hosts_.end()) { | 2095 if (iter != proxy_hosts_.end()) { |
2085 delete iter->second; | 2096 delete iter->second; |
2086 proxy_hosts_.erase(iter); | 2097 proxy_hosts_.erase(iter); |
2087 } | 2098 } |
2088 } | 2099 } |
2089 | 2100 |
2090 } // namespace content | 2101 } // namespace content |
OLD | NEW |