cef/patch/patches/content_2015.patch

557 lines
28 KiB
Diff
Raw Normal View History

diff --git chrome/browser/download/download_target_determiner.cc chrome/browser/download/download_target_determiner.cc
index 03ca8ad55078..0899131ab154 100644
--- chrome/browser/download/download_target_determiner.cc
+++ chrome/browser/download/download_target_determiner.cc
@@ -540,8 +540,8 @@ void IsHandledBySafePlugin(content::ResourceContext* resource_context,
content::PluginService* plugin_service =
content::PluginService::GetInstance();
bool plugin_found = plugin_service->GetPluginInfo(
- -1, -1, resource_context, url, url::Origin(), mime_type, false, &is_stale,
- &plugin_info, &actual_mime_type);
+ -1, -1, resource_context, url, true, url::Origin(), mime_type, false,
+ &is_stale, &plugin_info, &actual_mime_type);
if (is_stale && stale_plugin_action == RETRY_IF_STALE_PLUGIN_LIST) {
// The GetPlugins call causes the plugin list to be refreshed. Once that's
// done we can retry the GetPluginInfo call. We break out of this cycle
diff --git chrome/browser/plugins/chrome_plugin_service_filter.cc chrome/browser/plugins/chrome_plugin_service_filter.cc
index 8e6ef99239ab..24ceaf229702 100644
--- chrome/browser/plugins/chrome_plugin_service_filter.cc
+++ chrome/browser/plugins/chrome_plugin_service_filter.cc
@@ -178,6 +178,7 @@ bool ChromePluginServiceFilter::IsPluginAvailable(
int render_frame_id,
const void* context,
const GURL& plugin_content_url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
content::WebPluginInfo* plugin) {
base::AutoLock auto_lock(lock_);
diff --git chrome/browser/plugins/chrome_plugin_service_filter.h chrome/browser/plugins/chrome_plugin_service_filter.h
index 133145db74bf..021ab307ee2a 100644
--- chrome/browser/plugins/chrome_plugin_service_filter.h
+++ chrome/browser/plugins/chrome_plugin_service_filter.h
@@ -66,6 +66,7 @@ class ChromePluginServiceFilter : public content::PluginServiceFilter,
int render_frame_id,
const void* context,
const GURL& plugin_content_url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
content::WebPluginInfo* plugin) override;
diff --git chrome/browser/plugins/pdf_iframe_navigation_throttle.cc chrome/browser/plugins/pdf_iframe_navigation_throttle.cc
index 3b0948c90a00..f0fb3b5d9d55 100644
--- chrome/browser/plugins/pdf_iframe_navigation_throttle.cc
+++ chrome/browser/plugins/pdf_iframe_navigation_throttle.cc
@@ -53,7 +53,7 @@ PDFIFrameNavigationThrottle::MaybeCreateThrottleFor(
content::ResourceContext* resource_context =
handle->GetWebContents()->GetBrowserContext()->GetResourceContext();
if (filter->IsPluginAvailable(process_id, routing_id, resource_context,
- handle->GetURL(), url::Origin(),
+ handle->GetURL(), false, url::Origin(),
&pdf_plugin_info)) {
return nullptr;
}
diff --git chrome/browser/ui/cocoa/drag_util.mm chrome/browser/ui/cocoa/drag_util.mm
index b1a49f718226..cb56c9fd4765 100644
--- chrome/browser/ui/cocoa/drag_util.mm
+++ chrome/browser/ui/cocoa/drag_util.mm
@@ -51,7 +51,7 @@ BOOL IsSupportedFileURL(Profile* profile, const GURL& url) {
return PluginService::GetInstance()->GetPluginInfo(
-1, // process ID
MSG_ROUTING_NONE, // routing ID
- profile->GetResourceContext(), url, url::Origin(), mime_type,
+ profile->GetResourceContext(), url, true, url::Origin(), mime_type,
allow_wildcard, NULL, &plugin, NULL);
}
diff --git chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
index f4eb41e948bb..7e47a184d8c0 100644
--- chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
+++ chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
@@ -601,6 +601,6 @@ void BrowserTabStripController::OnFindURLMimeTypeCompleted(
content::PluginService::GetInstance()->GetPluginInfo(
-1, // process ID
MSG_ROUTING_NONE, // routing ID
- model_->profile()->GetResourceContext(), url, url::Origin(),
+ model_->profile()->GetResourceContext(), url, true, url::Origin(),
mime_type, false, NULL, &plugin, NULL));
}
diff --git content/browser/frame_host/navigation_handle_impl.cc content/browser/frame_host/navigation_handle_impl.cc
index 2986bf0e340e..6ef8486960ce 100644
--- content/browser/frame_host/navigation_handle_impl.cc
+++ content/browser/frame_host/navigation_handle_impl.cc
@@ -368,12 +368,6 @@ net::Error NavigationHandleImpl::GetNetErrorCode() {
}
RenderFrameHostImpl* NavigationHandleImpl::GetRenderFrameHost() {
- // TODO(mkwst): Change this to check against 'READY_TO_COMMIT' once
- // ReadyToCommitNavigation is available whether or not PlzNavigate is
- // enabled. https://crbug.com/621856
- CHECK_GE(state_, WILL_PROCESS_RESPONSE)
- << "This accessor should only be called after a response has been "
- "delivered for processing.";
return render_frame_host_;
}
diff --git content/browser/frame_host/render_frame_host_impl.cc content/browser/frame_host/render_frame_host_impl.cc
index 1f566ef1f437..cffef1c8a2f2 100644
--- content/browser/frame_host/render_frame_host_impl.cc
+++ content/browser/frame_host/render_frame_host_impl.cc
@@ -1527,6 +1527,7 @@ void RenderFrameHostImpl::OnDidFailProvisionalLoadWithError(
if (GetNavigationHandle()) {
GetNavigationHandle()->set_net_error_code(
static_cast<net::Error>(params.error_code));
+ GetNavigationHandle()->set_render_frame_host(this);
}
frame_tree_node_->navigator()->DidFailProvisionalLoadWithError(this, params);
@@ -3269,9 +3270,9 @@ void RenderFrameHostImpl::RegisterMojoInterfaces() {
&QuotaDispatcherHost::CreateForFrame, GetProcess(), routing_id_));
if (base::FeatureList::IsEnabled(network::features::kNetworkService)) {
- StoragePartitionImpl* storage_partition =
- static_cast<StoragePartitionImpl*>(BrowserContext::GetStoragePartition(
- GetSiteInstance()->GetBrowserContext(), GetSiteInstance()));
+ StoragePartition* storage_partition =
+ BrowserContext::GetStoragePartition(
+ GetSiteInstance()->GetBrowserContext(), GetSiteInstance());
// TODO(https://crbug.com/813479): Investigate why we need to explicitly
// specify task runner for BrowserThread::IO here.
// Bind calls to the BindRegistry should come on to the IO thread by
@@ -3545,9 +3546,9 @@ void RenderFrameHostImpl::CommitNavigation(
// however only do this for cross-document navigations, because the
// alternative would be redundant effort.
network::mojom::URLLoaderFactoryPtrInfo default_factory_info;
- StoragePartitionImpl* storage_partition =
- static_cast<StoragePartitionImpl*>(BrowserContext::GetStoragePartition(
- GetSiteInstance()->GetBrowserContext(), GetSiteInstance()));
+ StoragePartition* storage_partition =
+ BrowserContext::GetStoragePartition(
+ GetSiteInstance()->GetBrowserContext(), GetSiteInstance());
if (subresource_loader_params &&
subresource_loader_params->loader_factory_info.is_valid()) {
// If the caller has supplied a default URLLoaderFactory override (for
@@ -4162,8 +4163,8 @@ void RenderFrameHostImpl::CreateNetworkServiceDefaultFactoryAndObserve(
auto* context = GetSiteInstance()->GetBrowserContext();
GetContentClient()->browser()->WillCreateURLLoaderFactory(
this, false /* is_navigation */, &default_factory_request);
- StoragePartitionImpl* storage_partition = static_cast<StoragePartitionImpl*>(
- BrowserContext::GetStoragePartition(context, GetSiteInstance()));
+ StoragePartition* storage_partition =
+ BrowserContext::GetStoragePartition(context, GetSiteInstance());
if (g_create_network_factory_callback_for_test.Get().is_null()) {
storage_partition->GetNetworkContext()->CreateURLLoaderFactory(
std::move(default_factory_request), GetProcess()->GetID());
diff --git content/browser/frame_host/render_frame_message_filter.cc content/browser/frame_host/render_frame_message_filter.cc
index b3653373a51f..6db0652284ec 100644
--- content/browser/frame_host/render_frame_message_filter.cc
+++ content/browser/frame_host/render_frame_message_filter.cc
@@ -546,6 +546,7 @@ void RenderFrameMessageFilter::GetCookies(int render_frame_id,
void RenderFrameMessageFilter::OnGetPlugins(
bool refresh,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
IPC::Message* reply_msg) {
// Don't refresh if the specified threshold has not been passed. Note that
@@ -567,18 +568,19 @@ void RenderFrameMessageFilter::OnGetPlugins(
PluginServiceImpl::GetInstance()->GetPlugins(
base::BindOnce(&RenderFrameMessageFilter::GetPluginsCallback, this,
- reply_msg, main_frame_origin));
+ reply_msg, is_main_frame, main_frame_origin));
}
void RenderFrameMessageFilter::GetPluginsCallback(
IPC::Message* reply_msg,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::vector<WebPluginInfo>& all_plugins) {
// Filter the plugin list.
PluginServiceFilter* filter = PluginServiceImpl::GetInstance()->GetFilter();
std::vector<WebPluginInfo> plugins;
- int child_process_id = -1;
+ int child_process_id = render_process_id_;
int routing_id = MSG_ROUTING_NONE;
// In this loop, copy the WebPluginInfo (and do not use a reference) because
// the filter might mutate it.
@@ -587,7 +589,7 @@ void RenderFrameMessageFilter::GetPluginsCallback(
if (!filter ||
filter->IsPluginAvailable(child_process_id, routing_id,
resource_context_, main_frame_origin.GetURL(),
- main_frame_origin, &plugin)) {
+ is_main_frame, main_frame_origin, &plugin)) {
plugins.push_back(plugin);
}
}
@@ -599,6 +601,7 @@ void RenderFrameMessageFilter::GetPluginsCallback(
void RenderFrameMessageFilter::OnGetPluginInfo(
int render_frame_id,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::string& mime_type,
bool* found,
@@ -607,8 +610,8 @@ void RenderFrameMessageFilter::OnGetPluginInfo(
bool allow_wildcard = true;
*found = plugin_service_->GetPluginInfo(
render_process_id_, render_frame_id, resource_context_, url,
- main_frame_origin, mime_type, allow_wildcard, nullptr, info,
- actual_mime_type);
+ is_main_frame, main_frame_origin, mime_type, allow_wildcard, nullptr,
+ info, actual_mime_type);
}
void RenderFrameMessageFilter::OnOpenChannelToPepperPlugin(
diff --git content/browser/frame_host/render_frame_message_filter.h content/browser/frame_host/render_frame_message_filter.h
index db9398a07607..ce062d8a9ccd 100644
--- content/browser/frame_host/render_frame_message_filter.h
+++ content/browser/frame_host/render_frame_message_filter.h
@@ -136,13 +136,16 @@ class CONTENT_EXPORT RenderFrameMessageFilter
#if BUILDFLAG(ENABLE_PLUGINS)
void OnGetPlugins(bool refresh,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
IPC::Message* reply_msg);
void GetPluginsCallback(IPC::Message* reply_msg,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::vector<WebPluginInfo>& plugins);
void OnGetPluginInfo(int render_frame_id,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::string& mime_type,
bool* found,
diff --git content/browser/loader/mime_sniffing_resource_handler.cc content/browser/loader/mime_sniffing_resource_handler.cc
index a9322bc8b5d7..0b3bfef2237b 100644
--- content/browser/loader/mime_sniffing_resource_handler.cc
+++ content/browser/loader/mime_sniffing_resource_handler.cc
@@ -494,8 +494,8 @@ bool MimeSniffingResourceHandler::CheckForPluginHandler(
WebPluginInfo plugin;
bool has_plugin = plugin_service_->GetPluginInfo(
info->GetChildID(), info->GetRenderFrameID(), info->GetContext(),
- request()->url(), url::Origin(), response_->head.mime_type,
- allow_wildcard, &stale, &plugin, nullptr);
+ request()->url(), info->IsMainFrame(), url::Origin(),
+ response_->head.mime_type, allow_wildcard, &stale, &plugin, nullptr);
if (stale) {
// Refresh the plugins asynchronously.
diff --git content/browser/plugin_service_impl.cc content/browser/plugin_service_impl.cc
index 130f4d8e92e8..bade33e04c2e 100644
--- content/browser/plugin_service_impl.cc
+++ content/browser/plugin_service_impl.cc
@@ -262,6 +262,7 @@ bool PluginServiceImpl::GetPluginInfo(int render_process_id,
int render_frame_id,
ResourceContext* context,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::string& mime_type,
bool allow_wildcard,
@@ -278,7 +279,8 @@ bool PluginServiceImpl::GetPluginInfo(int render_process_id,
for (size_t i = 0; i < plugins.size(); ++i) {
if (!filter_ ||
filter_->IsPluginAvailable(render_process_id, render_frame_id, context,
- url, main_frame_origin, &plugins[i])) {
+ url, is_main_frame, main_frame_origin,
+ &plugins[i])) {
*info = plugins[i];
if (actual_mime_type)
*actual_mime_type = mime_types[i];
diff --git content/browser/plugin_service_impl.h content/browser/plugin_service_impl.h
index e6de4ca6c8b3..18eea4948e43 100644
--- content/browser/plugin_service_impl.h
+++ content/browser/plugin_service_impl.h
@@ -63,6 +63,7 @@ class CONTENT_EXPORT PluginServiceImpl : public PluginService {
int render_frame_id,
ResourceContext* context,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::string& mime_type,
bool allow_wildcard,
diff --git content/common/frame_messages.h content/common/frame_messages.h
index 8e482fa78e3a..99b8e486e88f 100644
--- content/common/frame_messages.h
+++ content/common/frame_messages.h
@@ -1362,8 +1362,9 @@ IPC_MESSAGE_ROUTED1(FrameHostMsg_PepperStopsPlayback,
// Used to get the list of plugins. |main_frame_origin| is used to handle
// exceptions for plugin content settings.
-IPC_SYNC_MESSAGE_CONTROL2_1(FrameHostMsg_GetPlugins,
+IPC_SYNC_MESSAGE_CONTROL3_1(FrameHostMsg_GetPlugins,
bool /* refresh*/,
+ bool /* is_main_frame */,
url::Origin /* main_frame_origin */,
std::vector<content::WebPluginInfo> /* plugins */)
@@ -1371,9 +1372,10 @@ IPC_SYNC_MESSAGE_CONTROL2_1(FrameHostMsg_GetPlugins,
// type. If there is no matching plugin, |found| is false.
// |actual_mime_type| is the actual mime type supported by the
// found plugin.
-IPC_SYNC_MESSAGE_CONTROL4_3(FrameHostMsg_GetPluginInfo,
+IPC_SYNC_MESSAGE_CONTROL5_3(FrameHostMsg_GetPluginInfo,
int /* render_frame_id */,
GURL /* url */,
+ bool /* is_main_frame */,
url::Origin /* main_frame_origin */,
std::string /* mime_type */,
bool /* found */,
diff --git content/ppapi_plugin/ppapi_blink_platform_impl.cc content/ppapi_plugin/ppapi_blink_platform_impl.cc
index bf3c786b5093..ea8f85700e86 100644
--- content/ppapi_plugin/ppapi_blink_platform_impl.cc
+++ content/ppapi_plugin/ppapi_blink_platform_impl.cc
@@ -199,6 +199,7 @@ blink::WebThemeEngine* PpapiBlinkPlatformImpl::ThemeEngine() {
void PpapiBlinkPlatformImpl::GetPluginList(
bool refresh,
+ bool isMainFrame,
const blink::WebSecurityOrigin& mainFrameOrigin,
blink::WebPluginListBuilder* builder) {
NOTREACHED();
diff --git content/ppapi_plugin/ppapi_blink_platform_impl.h content/ppapi_plugin/ppapi_blink_platform_impl.h
index 8a58a2ae1e2f..21b18ff2eba7 100644
--- content/ppapi_plugin/ppapi_blink_platform_impl.h
+++ content/ppapi_plugin/ppapi_blink_platform_impl.h
@@ -40,6 +40,7 @@ class PpapiBlinkPlatformImpl : public BlinkPlatformImpl {
blink::WebString DefaultLocale() override;
blink::WebThemeEngine* ThemeEngine() override;
void GetPluginList(bool refresh,
+ bool isMainFrame,
const blink::WebSecurityOrigin& mainFrameOrigin,
blink::WebPluginListBuilder*) override;
blink::WebData GetDataResource(const char* name) override;
diff --git content/public/browser/plugin_service.h content/public/browser/plugin_service.h
index ac05c13b1df8..762262bff01a 100644
--- content/public/browser/plugin_service.h
+++ content/public/browser/plugin_service.h
@@ -74,6 +74,7 @@ class PluginService {
int render_frame_id,
ResourceContext* context,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::string& mime_type,
bool allow_wildcard,
diff --git content/public/browser/plugin_service_filter.h content/public/browser/plugin_service_filter.h
index 3b610b1f554e..7c439e060779 100644
--- content/public/browser/plugin_service_filter.h
+++ content/public/browser/plugin_service_filter.h
@@ -33,6 +33,7 @@ class PluginServiceFilter {
int render_frame_id,
const void* context,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
WebPluginInfo* plugin) = 0;
diff --git content/public/renderer/content_renderer_client.h content/public/renderer/content_renderer_client.h
index 34aed4fd3565..364f042ee903 100644
--- content/public/renderer/content_renderer_client.h
+++ content/public/renderer/content_renderer_client.h
@@ -74,6 +74,9 @@ class CONTENT_EXPORT ContentRendererClient {
// Notifies us that the RenderThread has been created.
virtual void RenderThreadStarted() {}
+ // Notifies that the RenderThread can now send sync IPC messages.
+ virtual void RenderThreadConnected() {}
+
// Notifies that a new RenderFrame has been created.
virtual void RenderFrameCreated(RenderFrame* render_frame) {}
@@ -333,6 +336,10 @@ class CONTENT_EXPORT ContentRendererClient {
// This method may invalidate the frame.
virtual void RunScriptsAtDocumentIdle(RenderFrame* render_frame) {}
+ // Notifies that a DevTools agent has attached or detached.
+ virtual void DevToolsAgentAttached() {}
+ virtual void DevToolsAgentDetached() {}
+
// Allows subclasses to enable some runtime features before Blink has
// started.
virtual void SetRuntimeFeaturesDefaultsBeforeBlinkInitialization() {}
diff --git content/public/renderer/render_frame_observer.h content/public/renderer/render_frame_observer.h
index aa77b86eee98..097d26a80aa9 100644
--- content/public/renderer/render_frame_observer.h
+++ content/public/renderer/render_frame_observer.h
@@ -121,6 +121,9 @@ class CONTENT_EXPORT RenderFrameObserver : public IPC::Listener,
// load. This is used for UseCounter feature metrics.
virtual void DidObserveNewFeatureUsage(blink::mojom::WebFeature feature) {}
+ // Called when this frame gains focus.
+ virtual void FrameFocused() {}
+
// Called when the focused node has changed to |node|.
virtual void FocusedNodeChanged(const blink::WebNode& node) {}
diff --git content/renderer/render_frame_impl.cc content/renderer/render_frame_impl.cc
index 259d31191208..890ec89bbaee 100644
--- content/renderer/render_frame_impl.cc
+++ content/renderer/render_frame_impl.cc
@@ -3447,7 +3447,8 @@ blink::WebPlugin* RenderFrameImpl::CreatePlugin(
std::string mime_type;
bool found = false;
Send(new FrameHostMsg_GetPluginInfo(
- routing_id_, params.url, frame_->Top()->GetSecurityOrigin(),
+ routing_id_, params.url, frame_->Parent() == nullptr,
+ frame_->Top()->GetSecurityOrigin(),
params.mime_type.Utf8(), &found, &info, &mime_type));
if (!found)
return nullptr;
@@ -3808,6 +3809,8 @@ void RenderFrameImpl::FrameDetached(DetachType type) {
void RenderFrameImpl::FrameFocused() {
Send(new FrameHostMsg_FrameFocused(routing_id_));
+ for (auto& observer : observers_)
+ observer.FrameFocused();
}
void RenderFrameImpl::WillCommitProvisionalLoad() {
diff --git content/renderer/render_thread_impl.cc content/renderer/render_thread_impl.cc
index 81d3f80db8ef..1e349f80ed23 100644
--- content/renderer/render_thread_impl.cc
+++ content/renderer/render_thread_impl.cc
@@ -925,6 +925,8 @@ void RenderThreadImpl::Init(
StartServiceManagerConnection();
+ GetContentClient()->renderer()->RenderThreadConnected();
+
GetAssociatedInterfaceRegistry()->AddInterface(
base::Bind(&RenderThreadImpl::OnRendererInterfaceRequest,
base::Unretained(this)));
diff --git content/renderer/renderer_blink_platform_impl.cc content/renderer/renderer_blink_platform_impl.cc
index 0affacaa0294..8c08aad965a2 100644
--- content/renderer/renderer_blink_platform_impl.cc
+++ content/renderer/renderer_blink_platform_impl.cc
@@ -849,6 +849,7 @@ RendererBlinkPlatformImpl::CreateMIDIAccessor(
void RendererBlinkPlatformImpl::GetPluginList(
bool refresh,
+ bool isMainFrame,
const blink::WebSecurityOrigin& mainFrameOrigin,
blink::WebPluginListBuilder* builder) {
#if BUILDFLAG(ENABLE_PLUGINS)
@@ -856,7 +857,8 @@ void RendererBlinkPlatformImpl::GetPluginList(
if (!plugin_refresh_allowed_)
refresh = false;
RenderThread::Get()->Send(
- new FrameHostMsg_GetPlugins(refresh, mainFrameOrigin, &plugins));
+ new FrameHostMsg_GetPlugins(refresh, isMainFrame, mainFrameOrigin,
+ &plugins));
for (const WebPluginInfo& plugin : plugins) {
builder->AddPlugin(WebString::FromUTF16(plugin.name),
WebString::FromUTF16(plugin.desc),
@@ -1417,6 +1419,14 @@ void RendererBlinkPlatformImpl::RequestPurgeMemory() {
base::MemoryCoordinatorClientRegistry::GetInstance()->PurgeMemory();
}
+void RendererBlinkPlatformImpl::DevToolsAgentAttached() {
+ GetContentClient()->renderer()->DevToolsAgentAttached();
+}
+
+void RendererBlinkPlatformImpl::DevToolsAgentDetached() {
+ GetContentClient()->renderer()->DevToolsAgentDetached();
+}
+
void RendererBlinkPlatformImpl::InitializeWebDatabaseHostIfNeeded() {
if (!web_database_host_) {
web_database_host_ = blink::mojom::ThreadSafeWebDatabaseHostPtr::Create(
diff --git content/renderer/renderer_blink_platform_impl.h content/renderer/renderer_blink_platform_impl.h
index e8a4578009d1..780d8b29acb2 100644
--- content/renderer/renderer_blink_platform_impl.h
+++ content/renderer/renderer_blink_platform_impl.h
@@ -128,6 +128,7 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
viz::FrameSinkId GenerateFrameSinkId() override;
void GetPluginList(bool refresh,
+ bool isMainFrame,
const blink::WebSecurityOrigin& mainFrameOrigin,
blink::WebPluginListBuilder* builder) override;
blink::WebPublicSuffixList* PublicSuffixList() override;
@@ -256,6 +257,9 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
mojo::ScopedDataPipeConsumerHandle handle) override;
void RequestPurgeMemory() override;
+ void DevToolsAgentAttached() override;
+ void DevToolsAgentDetached() override;
+
// Returns non-null.
// It is invalid to call this in an incomplete env where
// RenderThreadImpl::current() returns nullptr (e.g. in some tests).
diff --git content/shell/browser/shell_plugin_service_filter.cc content/shell/browser/shell_plugin_service_filter.cc
index 3a48c59b7e3e..d10ef64adbba 100644
--- content/shell/browser/shell_plugin_service_filter.cc
+++ content/shell/browser/shell_plugin_service_filter.cc
@@ -18,6 +18,7 @@ bool ShellPluginServiceFilter::IsPluginAvailable(
int render_frame_id,
const void* context,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
WebPluginInfo* plugin) {
return plugin->name == base::ASCIIToUTF16("Blink Test Plugin") ||
diff --git content/shell/browser/shell_plugin_service_filter.h content/shell/browser/shell_plugin_service_filter.h
index 7767a620a9fd..8a95377f5f3b 100644
--- content/shell/browser/shell_plugin_service_filter.h
+++ content/shell/browser/shell_plugin_service_filter.h
@@ -21,6 +21,7 @@ class ShellPluginServiceFilter : public PluginServiceFilter {
int render_frame_id,
const void* context,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
WebPluginInfo* plugin) override;
diff --git content/test/fake_plugin_service.cc content/test/fake_plugin_service.cc
index 6746b9f16e7e..8634ada48d57 100644
--- content/test/fake_plugin_service.cc
+++ content/test/fake_plugin_service.cc
@@ -29,6 +29,7 @@ bool FakePluginService::GetPluginInfo(int render_process_id,
int render_frame_id,
ResourceContext* context,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::string& mime_type,
bool allow_wildcard,
diff --git content/test/fake_plugin_service.h content/test/fake_plugin_service.h
index db23a83ed079..57a4c536118c 100644
--- content/test/fake_plugin_service.h
+++ content/test/fake_plugin_service.h
@@ -30,6 +30,7 @@ class FakePluginService : public PluginService {
int render_frame_id,
ResourceContext* context,
const GURL& url,
+ bool is_main_frame,
const url::Origin& main_frame_origin,
const std::string& mime_type,
bool allow_wildcard,
diff --git content/test/test_blink_web_unit_test_support.cc content/test/test_blink_web_unit_test_support.cc
index 25182fdb0928..9cc19c4016d3 100644
--- content/test/test_blink_web_unit_test_support.cc
+++ content/test/test_blink_web_unit_test_support.cc
@@ -324,6 +324,7 @@ blink::WebThread* TestBlinkWebUnitTestSupport::CurrentThread() {
void TestBlinkWebUnitTestSupport::GetPluginList(
bool refresh,
+ bool is_main_frame,
const blink::WebSecurityOrigin& mainFrameOrigin,
blink::WebPluginListBuilder* builder) {
builder->AddPlugin("pdf", "pdf", "pdf-files");
diff --git content/test/test_blink_web_unit_test_support.h content/test/test_blink_web_unit_test_support.h
index d8ad7b6e4435..5eda4bc3c2d5 100644
--- content/test/test_blink_web_unit_test_support.h
+++ content/test/test_blink_web_unit_test_support.h
@@ -72,6 +72,7 @@ class TestBlinkWebUnitTestSupport : public BlinkPlatformImpl {
const blink::WebSize& size) override;
void GetPluginList(bool refresh,
+ bool is_main_frame,
const blink::WebSecurityOrigin& mainFrameOrigin,
blink::WebPluginListBuilder* builder) override;