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

Side by Side Diff: third_party/WebKit/Source/web/FrameLoaderClientImpl.cpp

Issue 2483703002: Replicate feature policy headers to remote frames (Closed)
Patch Set: Addressing review comments Created 4 years, 1 month 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 /* 1 /*
2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved.
3 * Copyright (C) 2011 Apple Inc. All rights reserved. 3 * Copyright (C) 2011 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 838 matching lines...) Expand 10 before | Expand all | Expand 10 after
849 } 849 }
850 850
851 void FrameLoaderClientImpl::didChangeSandboxFlags(Frame* childFrame, 851 void FrameLoaderClientImpl::didChangeSandboxFlags(Frame* childFrame,
852 SandboxFlags flags) { 852 SandboxFlags flags) {
853 if (!m_webFrame->client()) 853 if (!m_webFrame->client())
854 return; 854 return;
855 m_webFrame->client()->didChangeSandboxFlags( 855 m_webFrame->client()->didChangeSandboxFlags(
856 WebFrame::fromFrame(childFrame), static_cast<WebSandboxFlags>(flags)); 856 WebFrame::fromFrame(childFrame), static_cast<WebSandboxFlags>(flags));
857 } 857 }
858 858
859 void FrameLoaderClientImpl::didSetFeaturePolicyHeader(
860 const String& headerValue) {
861 if (m_webFrame->client())
862 m_webFrame->client()->didSetFeaturePolicyHeader(headerValue);
863 }
864
859 void FrameLoaderClientImpl::didAddContentSecurityPolicy( 865 void FrameLoaderClientImpl::didAddContentSecurityPolicy(
860 const String& headerValue, 866 const String& headerValue,
861 ContentSecurityPolicyHeaderType type, 867 ContentSecurityPolicyHeaderType type,
862 ContentSecurityPolicyHeaderSource source) { 868 ContentSecurityPolicyHeaderSource source) {
863 if (m_webFrame->client()) { 869 if (m_webFrame->client()) {
864 m_webFrame->client()->didAddContentSecurityPolicy( 870 m_webFrame->client()->didAddContentSecurityPolicy(
865 headerValue, static_cast<WebContentSecurityPolicyType>(type), 871 headerValue, static_cast<WebContentSecurityPolicyType>(type),
866 static_cast<WebContentSecurityPolicySource>(source)); 872 static_cast<WebContentSecurityPolicySource>(source));
867 } 873 }
868 } 874 }
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
974 WebDevToolsAgentImpl* FrameLoaderClientImpl::devToolsAgent() { 980 WebDevToolsAgentImpl* FrameLoaderClientImpl::devToolsAgent() {
975 return WebLocalFrameImpl::fromFrame(m_webFrame->frame()->localFrameRoot()) 981 return WebLocalFrameImpl::fromFrame(m_webFrame->frame()->localFrameRoot())
976 ->devToolsAgentImpl(); 982 ->devToolsAgentImpl();
977 } 983 }
978 984
979 KURL FrameLoaderClientImpl::overrideFlashEmbedWithHTML(const KURL& url) { 985 KURL FrameLoaderClientImpl::overrideFlashEmbedWithHTML(const KURL& url) {
980 return m_webFrame->client()->overrideFlashEmbedWithHTML(WebURL(url)); 986 return m_webFrame->client()->overrideFlashEmbedWithHTML(WebURL(url));
981 } 987 }
982 988
983 } // namespace blink 989 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698