mirror of
https://github.com/videojs/video.js.git
synced 2025-01-04 06:48:49 +02:00
Merge branch 'feature/disable-components'
This commit is contained in:
commit
5758472d2f
@ -1,3 +1,4 @@
|
||||
* Allow disabling of default components
|
||||
* Duration is now setable (need ed for HLS m3u8 files)
|
||||
* Event binders (on/off/one) now return the player instance
|
||||
* Stopped player from going back to beginningg on ended event.
|
||||
|
@ -77,6 +77,10 @@ _V_.Component = _V_.Class.extend({
|
||||
// Loop through components and add them to the player
|
||||
this.eachProp(options.components, function(name, opts){
|
||||
|
||||
// Allow for disabling default components
|
||||
// e.g. _V_.options.components.posterImage = false
|
||||
if (opts === false) return;
|
||||
|
||||
// Allow waiting to add components until a specific event is called
|
||||
var tempAdd = this.proxy(function(){
|
||||
// Set property name on player. Could cause conflicts with other prop names, but it's worth making refs easy.
|
||||
|
Loading…
Reference in New Issue
Block a user