1
0
Fork 0
forked from 0x2620/oxjs

fix bugs in video edit panel, clone some options

This commit is contained in:
rolux 2014-02-07 08:41:47 +00:00
commit 658b642887
2 changed files with 7 additions and 6 deletions

View file

@ -57,7 +57,7 @@ Ox.VideoEditPanel = function(options, self) {
clips: function() {
self.$clipPanel.options({
clips: Ox.clone(self.options.clips),
sort: self.options.sort
sort: Ox.clone(self.options.sort)
});
},
duration: function() {
@ -134,6 +134,7 @@ Ox.VideoEditPanel = function(options, self) {
movePositionTo('cut', -1);
},
key_control_c: function() {
// FIXME: this looks wrong, should copy getSelectedClips
that.triggerEvent('copy', [{
annotation: self.options.selected,
'in': self.options['in'],
@ -322,7 +323,7 @@ Ox.VideoEditPanel = function(options, self) {
showAnnotationsMap: self.options.showAnnotationsMap,
showLayers: self.options.showLayers,
showUsers: self.options.showUsers,
sort: self.options.sort,
sort: Ox.clone(self.options.sort),
sortOptions: self.options.sortOptions,
view: self.options.clipView,
width: self.options.clipSize
@ -362,7 +363,7 @@ Ox.VideoEditPanel = function(options, self) {
resize: resizeClips,
resizeend: resizeendClips,
select: function(data) {
self.options.selected = data;
self.options.selected = data.ids;
that.triggerEvent('select', data);
},
sort: function(data) {
@ -626,7 +627,7 @@ Ox.VideoEditPanel = function(options, self) {
});
}
that.getClipSelection = function() {
that.getSelectedClips = function() {
return self.options.selected.length ? self.options.selected.map(function(id) {
var clip = getClipById(id);
return clip.annotation || clip.item + '/' + clip['in'] + '-' + clip.out;