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

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

Issue 866173002: Plugin Power Saver: Add UI Overlay to throttled plugin using placeholder. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove stray comment. Created 5 years, 10 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..e23b3b0244586acd235e2a37c6755d5b61a04290 100644
--- a/content/renderer/pepper/plugin_instance_throttler_impl.h
+++ b/content/renderer/pepper/plugin_instance_throttler_impl.h
@@ -35,6 +35,7 @@ class CONTENT_EXPORT PluginInstanceThrottlerImpl
void RemoveObserver(Observer* observer) override;
bool IsThrottled() const override;
void MarkPluginEssential(PowerSaverUnthrottleMethod method) override;
+ void SetHiddenForPlaceholder(bool hidden) override;
bool needs_representative_keyframe() const {
return state_ == POWER_SAVER_ENABLED_AWAITING_KEYFRAME;
@@ -70,11 +71,16 @@ class CONTENT_EXPORT PluginInstanceThrottlerImpl
void EngageThrottle();
+ void TimeoutKeyframeExtraction();
+
State state_;
// Number of consecutive interesting frames we've encountered.
int consecutive_interesting_frames_;
+ // If true, take the next frame as the keyframe regardless of interestingness.
+ bool keyframe_extraction_timed_out_;
+
ObserverList<Observer> observer_list_;
base::WeakPtrFactory<PluginInstanceThrottlerImpl> weak_factory_;

Powered by Google App Engine
This is Rietveld 408576698