Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

valera-rozuvan
Copy link
Contributor

Title
"clicking outside of start/end time sends user to beginning of the video, instead of where she clicked."
https://edx-wiki.atlassian.net/browse/BLD-392

Description
A related issue (bug?) is that when the user clicks on the video timeline either before or after the specified end time, it jumps to the very beginning of the video (even if it's before the specified start time).

Technical details
This seems to be a YouTube feature. When start/end time is specified, the video doesn't play beyond the end time, and restarts playing (upon finish) from the beginning.

Tested with vanilla Google code example + start/end time parameters at http://jsfiddle.net/4hVWv/ .

Solution
Do not use YouTube API start and end properties. Handle these cases manually. I.e. pausing the video when the time reaches end time.

Reviewers

@ghost ghost assigned singingwolfboy Oct 25, 2013
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should correspond to <source> elements, which live inside <video> tags, I believe. As for why you're removing them, that I don't know. If the tests still pass without this line, then the line should be removed from the tests; if the tests fail without this line, then you know why it was needed. :)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

source tags should be removed to avoid memory leak bug that we had before. Removing of source tag, not video, stops loading video source and clears the memory.

@singingwolfboy
Copy link
Contributor

Once you mock the Javascript clock, I am 👍 on this PR.

@polesye
Copy link
Contributor

polesye commented Oct 29, 2013

Please update CHANGELOG.rst

@valera-rozuvan
Copy link
Contributor Author

@polesye I will update CHANGELOG.rst just before merging, in the final squashed commit.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use Number instead of speedFactor dict:

this.videoPlayer.startTime /= Number(this.speed);

Fix bug when the user clicks on the video time-line either
before or after the specified end time, it jumps
to the very beginning of the video.

BLD-392
valera-rozuvan added a commit that referenced this pull request Oct 31, 2013
…t_navigation

Bug fix: video end time proper seek beyond.
@valera-rozuvan valera-rozuvan merged commit 9b3bc84 into master Oct 31, 2013
@valera-rozuvan valera-rozuvan deleted the valera/bugfix_start_end_time_correct_navigation branch October 31, 2013 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants