mirror of
https://github.com/videojs/video.js.git
synced 2025-03-29 22:07:10 +02:00
@nickygerritsen scrubbing() is a method, not a property. closes #2411
This commit is contained in:
parent
8418a316d6
commit
fe65ffae65
@ -81,6 +81,7 @@ CHANGELOG
|
||||
* @misteroneill restore some properties on window.videojs. ([view](https://github.com/videojs/video.js/pull/2395))
|
||||
* @misteroneill restore some 4.x utilities and remove deprecated functionality ([view](https://github.com/videojs/video.js/pull/2406))
|
||||
* @heff use a synchronous ready() internally ([view](https://github.com/videojs/video.js/pull/2392))
|
||||
* @nickygerritsen scrubbing() is a method, not a property ([view](https://github.com/videojs/video.js/pull/2411))
|
||||
|
||||
--------------------
|
||||
|
||||
|
@ -43,13 +43,13 @@ class CurrentTimeDisplay extends Component {
|
||||
}
|
||||
|
||||
/**
|
||||
* Update current time display
|
||||
* Update current time display
|
||||
*
|
||||
* @method updateContent
|
||||
*/
|
||||
updateContent() {
|
||||
// Allows for smooth scrubbing, when player can't keep up.
|
||||
let time = (this.player_.scrubbing) ? this.player_.getCache().currentTime : this.player_.currentTime();
|
||||
let time = (this.player_.scrubbing()) ? this.player_.getCache().currentTime : this.player_.currentTime();
|
||||
let localizedText = this.localize('Current Time');
|
||||
let formattedTime = formatTime(time, this.player_.duration());
|
||||
this.contentEl_.innerHTML = `<span class="vjs-control-text">${localizedText}</span> ${formattedTime}`;
|
||||
|
@ -43,7 +43,7 @@ class RemainingTimeDisplay extends Component {
|
||||
}
|
||||
|
||||
/**
|
||||
* Update remaining time display
|
||||
* Update remaining time display
|
||||
*
|
||||
* @method updateContent
|
||||
*/
|
||||
@ -55,7 +55,7 @@ class RemainingTimeDisplay extends Component {
|
||||
}
|
||||
|
||||
// Allows for smooth scrubbing, when player can't keep up.
|
||||
// var time = (this.player_.scrubbing) ? this.player_.getCache().currentTime : this.player_.currentTime();
|
||||
// var time = (this.player_.scrubbing()) ? this.player_.getCache().currentTime : this.player_.currentTime();
|
||||
// this.contentEl_.innerHTML = vjs.formatTime(time, this.player_.duration());
|
||||
}
|
||||
|
||||
|
@ -113,7 +113,7 @@ class Slider extends Component {
|
||||
|
||||
// If scrubbing, we could use a cached value to make the handle keep up with the user's mouse.
|
||||
// On HTML5 browsers scrubbing is really smooth, but some flash players are slow, so we might want to utilize this later.
|
||||
// var progress = (this.player_.scrubbing) ? this.player_.getCache().currentTime / this.player_.duration() : this.player_.currentTime() / this.player_.duration();
|
||||
// var progress = (this.player_.scrubbing()) ? this.player_.getCache().currentTime / this.player_.duration() : this.player_.currentTime() / this.player_.duration();
|
||||
let progress = this.getPercent();
|
||||
let bar = this.bar;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user