[#1060] Made sure we reset the seeking flag after a seek #66

Merged
merged 3 commits into from May 29, 2012

Conversation

Projects
None yet
2 participants
Member

dseif commented May 14, 2012

No description provided.

players/vimeo/popcorn.vimeo.js
+ seeking = true;
@ScottDowne

ScottDowne May 17, 2012

Contributor

Where does this get turned off?

It won't set it to false in the event, as if( time.seconds !== currentTime ) { stops that.

@dseif

dseif May 17, 2012

Member

We actually don't even need this line as a seek gets triggered right after. Inside the seek listener for vimeo we do the currentTime check like you mentioned, so we should only set seeking = true then anyways. Gonna remove this.

players/vimeo/popcorn.vimeo.js
@@ -148,8 +156,8 @@
}
currentTime = seekTime = +val;
@ScottDowne

ScottDowne May 17, 2012

Contributor

You can probably blow all of this away:

          currentTime = seekTime = +val;

          seeking = true;
          media.dispatchEvent( "seeked" );
          media.dispatchEvent( "timeupdate" );
          vimeoObject.api_seekTo( currentTime );

and just call vimeo.api_seek( +val );

and remove the check in the vimeo seek event callback.

@dseif

dseif May 17, 2012

Member

good call

players/vimeo/popcorn.vimeo.js
@@ -50,9 +50,11 @@
vimeo_player_loaded.seek[ vimeoContainer.id ] = function( time ) {
if( time.seconds !== currentTime ) {
+ seeking = true;
currentTime = time.seconds;
media.dispatchEvent( "seeked" );
@ScottDowne

ScottDowne May 17, 2012

Contributor

Probably need a seeking event too? Does that exist?

@dseif

dseif May 17, 2012

Member

Don't know but i'll look into it

dseif added a commit that referenced this pull request May 29, 2012

Merge pull request #66 from dseif/t1060
[#1060] Made sure we reset the seeking flag after a seek

@dseif dseif merged commit 86281b8 into mozilla:master May 29, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment