fix setting position and paused state on timeline panel and player

This commit is contained in:
j 2012-05-26 19:01:05 +00:00
parent 68d50978ba
commit ba724933e8
2 changed files with 11 additions and 2 deletions

View file

@ -29,7 +29,7 @@ Ox.VideoTimelinePanel = function(options, self) {
loop: false, // fixme: used?
muted: false,
out: 0,
paused: false,
paused: true,
position: 0,
resolution: 0,
selected: '',
@ -74,7 +74,7 @@ Ox.VideoTimelinePanel = function(options, self) {
getLargeTimelineURL: self.options.getLargeTimelineURL,
height: self.options.height,
muted: self.options.muted,
paused: true,
paused: self.options.paused,
position: self.options.position,
resolution: self.options.resolution,
smallTimelineURL: self.options.smallTimelineURL,
@ -271,6 +271,12 @@ 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') {

View file

@ -799,6 +799,9 @@ Ox.VideoTimelinePlayer = function(options, self) {
self.setOption = function(key, value) {
if (key == 'height') {
setHeight();
} else if (key == 'paused') {
self.options.paused = !self.options.paused;
togglePaused();
} else if (key == 'position') {
setPosition();
} else if (key == 'width') {