forked from 0x2620/oxjs
self.setOption ~> that.update
This commit is contained in:
parent
9ee0742b53
commit
005d50c389
56 changed files with 919 additions and 933 deletions
|
|
@ -47,6 +47,25 @@ Ox.VideoTimelinePanel = function(options, self) {
|
|||
width: 0
|
||||
})
|
||||
.options(options || {})
|
||||
.update({
|
||||
height: function() {
|
||||
self.$player.options({height: self.options.height});
|
||||
},
|
||||
paused: function() {
|
||||
self.$player.options({
|
||||
paused: self.options.paused
|
||||
});
|
||||
},
|
||||
position: function() {
|
||||
setPosition(self.options.position);
|
||||
},
|
||||
showAnnotations: function() {
|
||||
that.$element.toggle(1);
|
||||
},
|
||||
width: function() {
|
||||
self.$player.options({width: getPlayerWidth()});
|
||||
}
|
||||
})
|
||||
.css({
|
||||
height: self.options.height + 'px',
|
||||
width: self.options.width + 'px'
|
||||
|
|
@ -268,22 +287,6 @@ Ox.VideoTimelinePanel = function(options, self) {
|
|||
});
|
||||
}
|
||||
|
||||
self.setOption = function(key, value) {
|
||||
if (key == 'height') {
|
||||
self.$player.options({height: value});
|
||||
} else if (key == 'paused') {
|
||||
self.$player.options({
|
||||
paused: value
|
||||
});
|
||||
} else if (key == 'position') {
|
||||
setPosition(value);
|
||||
} else if (key == 'showAnnotations') {
|
||||
that.$element.toggle(1);
|
||||
} else if (key == 'width') {
|
||||
self.$player.options({width: getPlayerWidth()});
|
||||
}
|
||||
};
|
||||
|
||||
/*@
|
||||
toggleAnnotations <f> toggle annotations
|
||||
() -> <o> toggle annotations
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue