| Index: third_party/WebKit/Source/core/html/media/AutoplayUmaHelper.h
|
| diff --git a/third_party/WebKit/Source/core/html/media/AutoplayUmaHelper.h b/third_party/WebKit/Source/core/html/media/AutoplayUmaHelper.h
|
| index 55b5e1302270e1210168348b7bef0889598cea2a..5924f596a0217b354f643c3d14b265cdf2631ae5 100644
|
| --- a/third_party/WebKit/Source/core/html/media/AutoplayUmaHelper.h
|
| +++ b/third_party/WebKit/Source/core/html/media/AutoplayUmaHelper.h
|
| @@ -9,6 +9,7 @@
|
| #include "core/dom/ContextLifecycleObserver.h"
|
| #include "core/events/EventListener.h"
|
| #include "platform/heap/Handle.h"
|
| +#include "public/platform/WebMediaPlayerClient.h"
|
|
|
| #include <set>
|
|
|
| @@ -70,6 +71,9 @@ class CORE_EXPORT AutoplayUmaHelper : public EventListener,
|
|
|
| void ContextDestroyed(ExecutionContext*) override;
|
|
|
| + // Called when source is initialized and loading starts.
|
| + void OnLoadStarted(WebMediaPlayer::LoadType);
|
| +
|
| void OnAutoplayInitiated(AutoplaySource);
|
|
|
| void RecordCrossOriginAutoplayResult(CrossOriginAutoplayResult);
|
| @@ -113,7 +117,7 @@ class CORE_EXPORT AutoplayUmaHelper : public EventListener,
|
| // The autoplay sources.
|
| std::set<AutoplaySource> sources_;
|
|
|
| - // The media element this UMA helper is attached to. |m_element| owns |this|.
|
| + // The media element this UMA helper is attached to. |element| owns |this|.
|
| Member<HTMLMediaElement> element_;
|
|
|
| // The observer is used to observe whether a muted video autoplaying by play()
|
| @@ -125,7 +129,7 @@ class CORE_EXPORT AutoplayUmaHelper : public EventListener,
|
| // -----------------------------------------------------------------------
|
| // Variables used for recording the duration of autoplay muted video playing
|
| // offscreen. The variables are valid when
|
| - // |m_autoplayOffscrenVisibilityObserver| is non-null.
|
| + // |autoplayOffscrenVisibilityObserver| is non-null.
|
| // The recording stops whenever the playback pauses or the page is unloaded.
|
|
|
| // The starting time of autoplaying muted video.
|
| @@ -144,6 +148,8 @@ class CORE_EXPORT AutoplayUmaHelper : public EventListener,
|
| // for recording as long as this observer is non-null.
|
| Member<ElementVisibilityObserver>
|
| muted_video_offscreen_duration_visibility_observer_;
|
| +
|
| + double load_start_time_ms_;
|
| };
|
|
|
| } // namespace blink
|
|
|