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

Unified Diff: content/renderer/render_frame_impl.cc

Issue 1497623002: Plugin Power Saver: Improve Poster behavior for essential plugins. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/render_frame_impl.cc
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index 0db8f24e912c0fabcddef7f30b37c8e696090b5a..2d27ce65a9ffd4af3c98e4107cae65978f8419a1 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -2089,15 +2089,13 @@ void RenderFrameImpl::RegisterPeripheralPlugin(
content_origin, unthrottle_callback);
}
-bool RenderFrameImpl::ShouldThrottleContent(
+RenderFrame::PeripheralContentStatus
+RenderFrameImpl::GetPeripheralContentStatus(
const url::Origin& main_frame_origin,
const url::Origin& content_origin,
- int width,
- int height,
- bool* cross_origin_main_content) const {
- return plugin_power_saver_helper_->ShouldThrottleContent(
- main_frame_origin, content_origin, width, height,
- cross_origin_main_content);
+ const gfx::Size& unobscured_size) const {
+ return plugin_power_saver_helper_->GetPeripheralContentStatus(
+ main_frame_origin, content_origin, unobscured_size);
}
void RenderFrameImpl::WhitelistContentOrigin(

Powered by Google App Engine
This is Rietveld 408576698