check for presence of annotations before acting on keyboard input
This commit is contained in:
parent
2a47b434a4
commit
99f9af5cd2
1 changed files with 3 additions and 9 deletions
|
@ -74,10 +74,10 @@ Ox.VideoEditor = function(options, self) {
|
|||
key_alt_shift_right: function() {
|
||||
},
|
||||
key_b: function() {
|
||||
selectAnnotation(getNextAnnotation('annotation', -1));
|
||||
self.annotations.length && selectAnnotation(getNextAnnotation('annotation', -1));
|
||||
},
|
||||
key_backslash: function() {
|
||||
selectAnnotation();
|
||||
self.annotations.length && selectAnnotation();
|
||||
},
|
||||
key_closebracket: function() {
|
||||
self.annotations.length && movePositionTo('annotation', 1);
|
||||
|
@ -128,7 +128,7 @@ Ox.VideoEditor = function(options, self) {
|
|||
self.options.videoSize == 'large' && toggleSize();
|
||||
},
|
||||
key_n: function() {
|
||||
selectAnnotation(getNextAnnotation('annotation', 1), true);
|
||||
self.annotations.length && selectAnnotation(getNextAnnotation('annotation', 1), true);
|
||||
},
|
||||
key_o: function() {
|
||||
setPoint('out', self.options.position);
|
||||
|
@ -143,12 +143,6 @@ Ox.VideoEditor = function(options, self) {
|
|||
key_s: function() {
|
||||
// toggleSize
|
||||
},
|
||||
key_shift_comma: function() {
|
||||
movePositionTo('match', -1);
|
||||
},
|
||||
key_shift_dot: function() {
|
||||
movePositionTo('match', 1);
|
||||
},
|
||||
key_shift_down: function() {
|
||||
movePositionBy(self.options.duration);
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue