changeMedia on iPhone autoplays when it should not #182

Closed
mdale opened this Issue Jun 29, 2012 · 2 comments

Projects

None yet

2 participants

@mdale

On the iPhone when you issue a change media call it after you have started the initial playback, the player state is not respected and playback automatically starts for the new entry. It should instead respect the original play state.

@ranyefet

We should only autoPlay video if autoPlay is true.
This has nothing to do with the previous play state.

We also need to clean up changeMedia flow. Looks like play events are sent even when it shouldn't.

Here's what I get when changing from second media to third without hitting the play button.
http://html5video.org/kgit/branches/develop/modules/KalturaSupport/tests/ChangeMediaEntry.qunit.html?forceMobileHTML5

First try - the correct behavior. the player switced source and showed the big play button. didn't autoplay:

EmbedPlayerNative:: playerSwitchSource> playing callback load.php:10922
EmbedPlayer:trigger pause:true load.php:10922
EmbedPlayer::pauseInterfaceUpdate load.php:10922
EmbedPlayerNative:: OnPaused:: propagate:true time since play: 342 isNative=true load.php:10922
EmbedPlayer::pauseInterfaceUpdate load.php:10922
EmbedPlayerNative:: setCurrentTime seekTime:0.01 count:8 load.php:10922
EmbedPlayerNative:: setCurrentTime: current time matches seek target: 0.01 == 0.01 

Second try - The player swiched source but the large play button didn't showed up:

EmbedPlayerNative:: playerSwitchSource> playing callback load.php:10922
EmbedPlayer:trigger pause:true load.php:10922
EmbedPlayer::pauseInterfaceUpdate load.php:10922
EmbedPlayerNative:: setCurrentTime seekTime:0.01 count:7 load.php:10922
EmbedPlayerNative:: OnPaused:: propagate:true time since play: 343 isNative=true load.php:10922
EmbedPlayer::pauseInterfaceUpdate load.php:10922
EmbedPlayerNative::onSeeking false new time: 0.009999999776482582 load.php:10922
EmbedPlayerNative::seeking:trigger:: true load.php:10922
EmbedPlayerNative::onSeeked true ct:0.009999999776482582 load.php:10922
EmbedPlayerNative:: trigger: seeked load.php:10922
KAnalytics :: doSendAnalyticsEvent > SEEK load.php:10922
PlayerControlBuilder::change:update volume:0.75 load.php:10922
EmbedPlayer::bufferStart load.php:10922
KAnalytics :: doSendAnalyticsEvent > BUFFER_START load.php:10922
KAnalytics :: doSendAnalyticsEvent > BUFFER_END 

Third try - The player switched entry and start playback:

EmbedPlayerNative:: playerSwitchSource> playing callback load.php:10922
EmbedPlayer:trigger pause:true load.php:10922
EmbedPlayer::pauseInterfaceUpdate load.php:10922
EmbedPlayerNative:: OnPaused:: propagate:true time since play: 104 isNative=true load.php:10922
EmbedPlayerNative:: OnPlay:: propogate:true paused: true load.php:10922
EmbedPlayer:: play: true poster: false load.php:10922
EmbedPlayer:: trigger play event::true events:true load.php:10922
EmbedPlayer:: playInterfaceUpdate load.php:10922
EmbedPlayerNative:: setCurrentTime seekTime:0.01 count:3 load.php:10922
EmbedPlayerNative::onSeeking false new time: 0.009999999776482582 load.php:10922
EmbedPlayerNative::seeking:trigger:: true load.php:10922
EmbedPlayerNative::onSeeked true ct:0.009999999776482582 load.php:10922
EmbedPlayerNative:: trigger: seeked load.php:10922
KAnalytics :: doSendAnalyticsEvent > SEEK load.php:10922
PlayerControlBuilder::change:update volume:0.75 load.php:10922
EmbedPlayer::bufferStart load.php:10922
KAnalytics :: doSendAnalyticsEvent > BUFFER_START load.php:10922
KAnalytics :: doSendAnalyticsEvent > BUFFER_END 
@mdale mdale pushed a commit that referenced this issue Aug 15, 2012
Michael Dale fix for #182 use ignoreNextNative event in onpause as well. 103d2b2
@mdale

103d2b2 closes this issue.

@mdale mdale closed this Aug 15, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment