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

Unified Diff: content/renderer/pepper/plugin_power_saver_helper.h

Issue 707113002: Plugin Power Saver: Refactor Plugin Instance Throttling code (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@0190-plugin-power-saver-add-some-umas
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/pepper/pepper_plugin_instance_throttler_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/pepper/plugin_power_saver_helper.h
diff --git a/content/renderer/pepper/plugin_power_saver_helper.h b/content/renderer/pepper/plugin_power_saver_helper.h
index e4678a63464678c3596a133707467842d9176bb8..5cca041fdfc9ee1774cabfade3e7c2a3d48d583b 100644
--- a/content/renderer/pepper/plugin_power_saver_helper.h
+++ b/content/renderer/pepper/plugin_power_saver_helper.h
@@ -33,18 +33,19 @@ class CONTENT_EXPORT PluginPowerSaverHelper : public RenderFrameObserver {
// - Same-origin: a.com -> b.com/iframe-to-a.html -> a.com/plugin.swf
//
// |cross_origin| may not be NULL.
- bool ShouldThrottleContent(const GURL& content_origin,
- int width,
- int height,
- bool* cross_origin) const;
+ virtual bool ShouldThrottleContent(const GURL& content_origin,
+ int width,
+ int height,
+ bool* cross_origin) const;
// Registers a plugin that has been marked peripheral. If the origin
// whitelist is later updated and includes |content_origin|, then
// |unthrottle_callback| will be called.
- void RegisterPeripheralPlugin(const GURL& content_origin,
- const base::Closure& unthrottle_callback);
+ virtual void RegisterPeripheralPlugin(
+ const GURL& content_origin,
+ const base::Closure& unthrottle_callback);
- void WhitelistContentOrigin(const GURL& content_origin);
+ virtual void WhitelistContentOrigin(const GURL& content_origin);
private:
struct PeripheralPlugin {
« no previous file with comments | « content/renderer/pepper/pepper_plugin_instance_throttler_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698