Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(626)

Side by Side Diff: content/browser/frame_host/render_frame_host_manager.cc

Issue 1938753002: OOPIF: Replicate allowFullscreen flag. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Cleanup Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <utility> 10 #include <utility>
(...skipping 930 matching lines...) Expand 10 before | Expand all | Expand 10 after
941 bool should_enforce) { 941 bool should_enforce) {
942 if (!SiteIsolationPolicy::AreCrossProcessFramesPossible()) 942 if (!SiteIsolationPolicy::AreCrossProcessFramesPossible())
943 return; 943 return;
944 944
945 for (const auto& pair : proxy_hosts_) { 945 for (const auto& pair : proxy_hosts_) {
946 pair.second->Send(new FrameMsg_EnforceStrictMixedContentChecking( 946 pair.second->Send(new FrameMsg_EnforceStrictMixedContentChecking(
947 pair.second->GetRoutingID(), should_enforce)); 947 pair.second->GetRoutingID(), should_enforce));
948 } 948 }
949 } 949 }
950 950
951 void RenderFrameHostManager::OnDidUpdateFrameOwnerProperties(
952 const blink::WebFrameOwnerProperties& properties) {
953 if (!SiteIsolationPolicy::AreCrossProcessFramesPossible())
954 return;
955
956 // WebFrameOwnerProperties exist only for frames that have a parent.
957 CHECK(frame_tree_node_->parent());
958 SiteInstance* parent_instance =
959 frame_tree_node_->parent()->current_frame_host()->GetSiteInstance();
960
961 // Notify the RenderFrame if it lives in a different process from its parent.
962 if (render_frame_host_->GetSiteInstance() != parent_instance) {
963 render_frame_host_->Send(new FrameMsg_SetFrameOwnerProperties(
964 render_frame_host_->GetRoutingID(), properties));
965 }
966
967 // Notify this frame's proxies if they live in a different process from its
968 // parent.
969 //
970 // TODO(alexmos): It would be sufficient to only send this update to proxies
971 // in the current FrameTree.
972 for (const auto& pair : proxy_hosts_) {
973 if (pair.second->GetSiteInstance() != parent_instance) {
974 pair.second->Send(new FrameMsg_SetFrameOwnerProperties(
975 pair.second->GetRoutingID(), properties));
976 }
977 }
978 }
979
951 void RenderFrameHostManager::OnDidUpdateOrigin( 980 void RenderFrameHostManager::OnDidUpdateOrigin(
952 const url::Origin& origin, 981 const url::Origin& origin,
953 bool is_potentially_trustworthy_unique_origin) { 982 bool is_potentially_trustworthy_unique_origin) {
954 for (const auto& pair : proxy_hosts_) { 983 for (const auto& pair : proxy_hosts_) {
955 pair.second->Send( 984 pair.second->Send(
956 new FrameMsg_DidUpdateOrigin(pair.second->GetRoutingID(), origin, 985 new FrameMsg_DidUpdateOrigin(pair.second->GetRoutingID(), origin,
957 is_potentially_trustworthy_unique_origin)); 986 is_potentially_trustworthy_unique_origin));
958 } 987 }
959 } 988 }
960 989
(...skipping 1586 matching lines...) Expand 10 before | Expand all | Expand 10 after
2547 resolved_url)) { 2576 resolved_url)) {
2548 DCHECK(!dest_instance || 2577 DCHECK(!dest_instance ||
2549 dest_instance == render_frame_host_->GetSiteInstance()); 2578 dest_instance == render_frame_host_->GetSiteInstance());
2550 return false; 2579 return false;
2551 } 2580 }
2552 2581
2553 return true; 2582 return true;
2554 } 2583 }
2555 2584
2556 } // namespace content 2585 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698