| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/renderer/render_frame_proxy.h" | 5 #include "content/renderer/render_frame_proxy.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 #include <map> | 8 #include <map> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| 11 #include "base/command_line.h" | 11 #include "base/command_line.h" |
| 12 #include "base/lazy_instance.h" | 12 #include "base/lazy_instance.h" |
| 13 #include "content/child/feature_policy/feature_policy_platform.h" | 13 #include "content/child/feature_policy/feature_policy_platform.h" |
| 14 #include "content/child/web_url_request_util.h" | 14 #include "content/child/web_url_request_util.h" |
| 15 #include "content/child/webmessageportchannel_impl.h" | 15 #include "content/child/webmessageportchannel_impl.h" |
| 16 #include "content/common/content_security_policy_header.h" | 16 #include "content/common/content_security_policy_header.h" |
| 17 #include "content/common/content_switches_internal.h" | 17 #include "content/common/content_switches_internal.h" |
| 18 #include "content/common/frame_messages.h" | 18 #include "content/common/frame_messages.h" |
| 19 #include "content/common/frame_owner_properties.h" | 19 #include "content/common/frame_owner_properties.h" |
| 20 #include "content/common/frame_replication_state.h" | 20 #include "content/common/frame_replication_state.h" |
| 21 #include "content/common/input_messages.h" | 21 #include "content/common/input_messages.h" |
| 22 #include "content/common/page_messages.h" | 22 #include "content/common/page_messages.h" |
| 23 #include "content/common/site_isolation_policy.h" | 23 #include "content/common/site_isolation_policy.h" |
| 24 #include "content/common/swapped_out_messages.h" | 24 #include "content/common/swapped_out_messages.h" |
| 25 #include "content/common/view_messages.h" | 25 #include "content/common/view_messages.h" |
| 26 #include "content/renderer/child_frame_compositing_helper.h" | 26 #include "content/renderer/child_frame_compositing_helper.h" |
| 27 #include "content/renderer/frame_owner_properties.h" |
| 27 #include "content/renderer/render_frame_impl.h" | 28 #include "content/renderer/render_frame_impl.h" |
| 28 #include "content/renderer/render_thread_impl.h" | 29 #include "content/renderer/render_thread_impl.h" |
| 29 #include "content/renderer/render_view_impl.h" | 30 #include "content/renderer/render_view_impl.h" |
| 30 #include "content/renderer/render_widget.h" | 31 #include "content/renderer/render_widget.h" |
| 31 #include "ipc/ipc_message_macros.h" | 32 #include "ipc/ipc_message_macros.h" |
| 32 #include "third_party/WebKit/public/platform/URLConversion.h" | 33 #include "third_party/WebKit/public/platform/URLConversion.h" |
| 33 #include "third_party/WebKit/public/platform/WebFeaturePolicy.h" | 34 #include "third_party/WebKit/public/platform/WebFeaturePolicy.h" |
| 34 #include "third_party/WebKit/public/platform/WebRect.h" | 35 #include "third_party/WebKit/public/platform/WebRect.h" |
| 35 #include "third_party/WebKit/public/platform/WebString.h" | 36 #include "third_party/WebKit/public/platform/WebString.h" |
| 36 #include "third_party/WebKit/public/web/WebLocalFrame.h" | 37 #include "third_party/WebKit/public/web/WebLocalFrame.h" |
| (...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 361 web_frame_->resetReplicatedContentSecurityPolicy(); | 362 web_frame_->resetReplicatedContentSecurityPolicy(); |
| 362 } | 363 } |
| 363 | 364 |
| 364 void RenderFrameProxy::OnEnforceInsecureRequestPolicy( | 365 void RenderFrameProxy::OnEnforceInsecureRequestPolicy( |
| 365 blink::WebInsecureRequestPolicy policy) { | 366 blink::WebInsecureRequestPolicy policy) { |
| 366 web_frame_->setReplicatedInsecureRequestPolicy(policy); | 367 web_frame_->setReplicatedInsecureRequestPolicy(policy); |
| 367 } | 368 } |
| 368 | 369 |
| 369 void RenderFrameProxy::OnSetFrameOwnerProperties( | 370 void RenderFrameProxy::OnSetFrameOwnerProperties( |
| 370 const FrameOwnerProperties& properties) { | 371 const FrameOwnerProperties& properties) { |
| 371 web_frame_->setFrameOwnerProperties(properties.ToWebFrameOwnerProperties()); | 372 web_frame_->setFrameOwnerProperties( |
| 373 ConvertFrameOwnerPropertiesToWebFrameOwnerProperties(properties)); |
| 372 } | 374 } |
| 373 | 375 |
| 374 void RenderFrameProxy::OnDidUpdateOrigin( | 376 void RenderFrameProxy::OnDidUpdateOrigin( |
| 375 const url::Origin& origin, | 377 const url::Origin& origin, |
| 376 bool is_potentially_trustworthy_unique_origin) { | 378 bool is_potentially_trustworthy_unique_origin) { |
| 377 web_frame_->setReplicatedOrigin(origin); | 379 web_frame_->setReplicatedOrigin(origin); |
| 378 web_frame_->setReplicatedPotentiallyTrustworthyUniqueOrigin( | 380 web_frame_->setReplicatedPotentiallyTrustworthyUniqueOrigin( |
| 379 is_potentially_trustworthy_unique_origin); | 381 is_potentially_trustworthy_unique_origin); |
| 380 } | 382 } |
| 381 | 383 |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 525 blink::WebLocalFrame* source) { | 527 blink::WebLocalFrame* source) { |
| 526 int source_routing_id = RenderFrameImpl::FromWebFrame(source)->GetRoutingID(); | 528 int source_routing_id = RenderFrameImpl::FromWebFrame(source)->GetRoutingID(); |
| 527 Send(new FrameHostMsg_AdvanceFocus(routing_id_, type, source_routing_id)); | 529 Send(new FrameHostMsg_AdvanceFocus(routing_id_, type, source_routing_id)); |
| 528 } | 530 } |
| 529 | 531 |
| 530 void RenderFrameProxy::frameFocused() { | 532 void RenderFrameProxy::frameFocused() { |
| 531 Send(new FrameHostMsg_FrameFocused(routing_id_)); | 533 Send(new FrameHostMsg_FrameFocused(routing_id_)); |
| 532 } | 534 } |
| 533 | 535 |
| 534 } // namespace | 536 } // namespace |
| OLD | NEW |