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

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

Issue 879403002: Plugin Power Saver: Mute throttled plugins. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 months 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/pepper/plugin_instance_throttler_impl.h
diff --git a/content/renderer/pepper/plugin_instance_throttler_impl.h b/content/renderer/pepper/plugin_instance_throttler_impl.h
index 14352c119b204e5b736ef010e86d6c1ef3c3a68a..1a9b62b7967fe8831cb27cdd9e9d8adb76097527 100644
--- a/content/renderer/pepper/plugin_instance_throttler_impl.h
+++ b/content/renderer/pepper/plugin_instance_throttler_impl.h
@@ -55,22 +55,9 @@ class CONTENT_EXPORT PluginInstanceThrottlerImpl
private:
friend class PluginInstanceThrottlerImplTest;
- enum State {
- // Initial state if Power Saver is disabled. We are just collecting metrics.
- POWER_SAVER_DISABLED,
- // Initial state if Power Saver is enabled. Waiting for a keyframe.
- POWER_SAVER_ENABLED_AWAITING_KEYFRAME,
- // We've chosen a keyframe and the plug-in is throttled.
- POWER_SAVER_ENABLED_PLUGIN_THROTTLED,
- // Plugin instance is no longer considered peripheral. This can happen from
- // a user click, whitelisting, or some other reason. We can end up in this
- // state regardless of whether power saver is enabled.
- PLUGIN_INSTANCE_MARKED_ESSENTIAL
- };
-
void EngageThrottle();
- State state_;
+ PowerSaverState state_;
// Number of consecutive interesting frames we've encountered.
int consecutive_interesting_frames_;

Powered by Google App Engine
This is Rietveld 408576698