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

Unified Diff: media/blink/webmediaplayer_impl.h

Issue 2160963002: Add watch time metrics for HTML5 media playback. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Comments. Created 4 years, 4 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
« no previous file with comments | « media/blink/watch_time_reporter_unittest.cc ('k') | media/blink/webmediaplayer_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/webmediaplayer_impl.h
diff --git a/media/blink/webmediaplayer_impl.h b/media/blink/webmediaplayer_impl.h
index 9fb661d1bfef88c57f73171bba0a1b74013bcd64..f12d951ce8eb8a280bd3643b4dbfbad6dd8476e0 100644
--- a/media/blink/webmediaplayer_impl.h
+++ b/media/blink/webmediaplayer_impl.h
@@ -72,6 +72,7 @@ class GpuVideoAcceleratorFactories;
class MediaLog;
class UrlIndex;
class VideoFrameCompositor;
+class WatchTimeReporter;
class WebAudioSourceProviderImpl;
class WebMediaPlayerDelegate;
class WebTextTrackImpl;
@@ -349,6 +350,8 @@ class MEDIA_BLINK_EXPORT WebMediaPlayerImpl
// paused state after some idle timeout.
void ScheduleIdlePauseTimer();
+ void CreateWatchTimeReporter();
+
blink::WebLocalFrame* frame_;
// The playback state last reported to |delegate_|, to avoid setting duplicate
@@ -535,6 +538,10 @@ class MEDIA_BLINK_EXPORT WebMediaPlayerImpl
// state as part of the call to OnHidden().
base::OneShotTimer background_pause_timer_;
+ // Monitors the watch time of the played content.
+ std::unique_ptr<WatchTimeReporter> watch_time_reporter_;
+ bool is_encrypted_;
+
DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl);
};
« no previous file with comments | « media/blink/watch_time_reporter_unittest.cc ('k') | media/blink/webmediaplayer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698