fix setting position and paused state on timeline panel and player
This commit is contained in:
parent
68d50978ba
commit
ba724933e8
2 changed files with 11 additions and 2 deletions
|
@ -29,7 +29,7 @@ Ox.VideoTimelinePanel = function(options, self) {
|
||||||
loop: false, // fixme: used?
|
loop: false, // fixme: used?
|
||||||
muted: false,
|
muted: false,
|
||||||
out: 0,
|
out: 0,
|
||||||
paused: false,
|
paused: true,
|
||||||
position: 0,
|
position: 0,
|
||||||
resolution: 0,
|
resolution: 0,
|
||||||
selected: '',
|
selected: '',
|
||||||
|
@ -74,7 +74,7 @@ Ox.VideoTimelinePanel = function(options, self) {
|
||||||
getLargeTimelineURL: self.options.getLargeTimelineURL,
|
getLargeTimelineURL: self.options.getLargeTimelineURL,
|
||||||
height: self.options.height,
|
height: self.options.height,
|
||||||
muted: self.options.muted,
|
muted: self.options.muted,
|
||||||
paused: true,
|
paused: self.options.paused,
|
||||||
position: self.options.position,
|
position: self.options.position,
|
||||||
resolution: self.options.resolution,
|
resolution: self.options.resolution,
|
||||||
smallTimelineURL: self.options.smallTimelineURL,
|
smallTimelineURL: self.options.smallTimelineURL,
|
||||||
|
@ -271,6 +271,12 @@ Ox.VideoTimelinePanel = function(options, self) {
|
||||||
self.setOption = function(key, value) {
|
self.setOption = function(key, value) {
|
||||||
if (key == 'height') {
|
if (key == 'height') {
|
||||||
self.$player.options({height: value});
|
self.$player.options({height: value});
|
||||||
|
} else if (key == 'paused') {
|
||||||
|
self.$player.options({
|
||||||
|
paused: value
|
||||||
|
});
|
||||||
|
} else if (key == 'position') {
|
||||||
|
setPosition(value);
|
||||||
} else if (key == 'showAnnotations') {
|
} else if (key == 'showAnnotations') {
|
||||||
that.$element.toggle(1);
|
that.$element.toggle(1);
|
||||||
} else if (key == 'width') {
|
} else if (key == 'width') {
|
||||||
|
|
|
@ -799,6 +799,9 @@ Ox.VideoTimelinePlayer = function(options, self) {
|
||||||
self.setOption = function(key, value) {
|
self.setOption = function(key, value) {
|
||||||
if (key == 'height') {
|
if (key == 'height') {
|
||||||
setHeight();
|
setHeight();
|
||||||
|
} else if (key == 'paused') {
|
||||||
|
self.options.paused = !self.options.paused;
|
||||||
|
togglePaused();
|
||||||
} else if (key == 'position') {
|
} else if (key == 'position') {
|
||||||
setPosition();
|
setPosition();
|
||||||
} else if (key == 'width') {
|
} else if (key == 'width') {
|
||||||
|
|
Loading…
Reference in a new issue