Update to Chromium revision fc6aaca4 (#406441)

This commit is contained in:
Marshall Greenblatt
2016-07-21 17:21:32 -04:00
parent d92bc1d200
commit 98f59f47fd
79 changed files with 478 additions and 402 deletions

View File

@ -60,7 +60,7 @@ CefPluginPlaceholder::CefPluginPlaceholder(
status_(CefViewHostMsg_GetPluginInfo_Status::kAllowed),
title_(title),
context_menu_request_id_(0),
ignore_updates_(false) {
did_send_blocked_content_notification_(false) {
RenderThread::Get()->AddObserver(this);
}
@ -286,29 +286,10 @@ blink::WebPlugin* CefPluginPlaceholder::CreatePlugin() {
GetPluginParams(), std::move(throttler));
}
void CefPluginPlaceholder::OnLoadedRectUpdate(
const gfx::Rect& unobscured_rect,
content::RenderFrame::PeripheralContentStatus status) {
// If the placeholder is in the blocked state, do nothing.
if (ignore_updates_)
void CefPluginPlaceholder::OnBlockedTinyContent() {
if (did_send_blocked_content_notification_)
return;
// This should only be called once.
set_delayed(false);
// block tiny cross-origin - simply by not continuing the load chain.
if (status ==
content::RenderFrame::CONTENT_STATUS_ESSENTIAL_CROSS_ORIGIN_TINY) {
ignore_updates_ = true;
return;
}
// For essential content, powersaver can be turned off.
if (status != content::RenderFrame::CONTENT_STATUS_PERIPHERAL)
set_power_saver_enabled(false);
AllowLoading();
LoadPlugin();
did_send_blocked_content_notification_ = true;
}
gin::ObjectTemplateBuilder CefPluginPlaceholder::GetObjectTemplateBuilder(

View File

@ -52,9 +52,7 @@ class CefPluginPlaceholder final
// content::LoadablePluginPlaceholder overrides:
blink::WebPlugin* CreatePlugin() override;
void OnLoadedRectUpdate(
const gfx::Rect& unobscured_rect,
content::RenderFrame::PeripheralContentStatus status) override;
void OnBlockedTinyContent() override;
// gin::Wrappable (via PluginPlaceholder) method
gin::ObjectTemplateBuilder GetObjectTemplateBuilder(
@ -85,7 +83,7 @@ class CefPluginPlaceholder final
int context_menu_request_id_; // Nonzero when request pending.
base::string16 plugin_name_;
bool ignore_updates_;
bool did_send_blocked_content_notification_;
DISALLOW_COPY_AND_ASSIGN(CefPluginPlaceholder);
};