Index: Source/core/html/HTMLMediaElement.h |
diff --git a/Source/core/html/HTMLMediaElement.h b/Source/core/html/HTMLMediaElement.h |
index 3bda86b84467989e361bb0f08f00516d1c77b77c..b26c95eecea1a0455548036b29b7c0d4d02942b2 100644 |
--- a/Source/core/html/HTMLMediaElement.h |
+++ b/Source/core/html/HTMLMediaElement.h |
@@ -364,7 +364,6 @@ private: |
void loadResource(const KURL&, ContentType&, const String& keySystem); |
void startPlayerLoad(); |
void setPlayerPreload(); |
- void startDelayedLoad(); |
blink::WebMediaPlayer::LoadType loadType() const; |
void scheduleNextSourceChild(); |
void loadNextSourceChild(); |
@@ -382,6 +381,14 @@ private: |
void mediaLoadingFailed(MediaPlayer::NetworkState); |
+ // deferred loading (preload=none) |
+ bool loadIsDeferred() const; |
+ void deferLoad(); |
+ void cancelDeferredLoad(); |
+ void startDeferredLoad(); |
+ void executeDeferredLoad(); |
+ void deferredLoadTimerFired(Timer<HTMLMediaElement>*); |
+ |
void updateActiveTextTrackCues(double); |
HTMLTrackElement* showingTrackWithSameKind(HTMLTrackElement*) const; |
@@ -461,6 +468,22 @@ private: |
RefPtrWillBeMember<HTMLSourceElement> m_currentSourceNode; |
RefPtrWillBeMember<Node> m_nextChildNodeToConsider; |
+ // "Deferred loading" state (for preload=none). |
+ enum DeferredLoadState { |
+ // The load is not deferred. |
+ NotDeferred, |
+ // The load is deferred, and waiting for the task to set the |
+ // delaying-the-load-event flag (to false). |
+ WaitingForStopDelayingLoadEventTask, |
+ // The load is the deferred, and waiting for a triggering event. |
+ WaitingForTrigger, |
+ // The load is deferred, and waiting for the task to set the |
+ // delaying-the-load-event flag, after which the load will be executed. |
+ ExecuteOnStopDelayingLoadEventTask |
+ }; |
+ DeferredLoadState m_deferredLoadState; |
+ Timer<HTMLMediaElement> m_deferredLoadTimer; |
+ |
OwnPtr<MediaPlayer> m_player; |
blink::WebLayer* m_webLayer; |