From c040e4860162c5c9721945f439e20d447547efa1 Mon Sep 17 00:00:00 2001 From: rlx <0x0073@0x2620.org> Date: Wed, 15 Feb 2012 22:06:00 +0000 Subject: [PATCH] beginning to fix #318 --- source/Ox.UI/js/Video/Ox.AnnotationFolder.js | 23 ++++++++++++++++- source/Ox.UI/js/Video/Ox.AnnotationPanel.js | 27 +++++++++++++++++--- source/Ox.UI/js/Video/Ox.VideoEditor.js | 27 ++++++++++++++++++-- 3 files changed, 71 insertions(+), 6 deletions(-) diff --git a/source/Ox.UI/js/Video/Ox.AnnotationFolder.js b/source/Ox.UI/js/Video/Ox.AnnotationFolder.js index 817c2707..783fe08f 100644 --- a/source/Ox.UI/js/Video/Ox.AnnotationFolder.js +++ b/source/Ox.UI/js/Video/Ox.AnnotationFolder.js @@ -261,8 +261,29 @@ Ox.AnnotationFolder = function(options, self) { that.triggerEvent('selectnone'); }, submit: submitAnnotation, + key_b: function() { + that.triggerEvent('key_b'); + }, + key_equal: function() { + that.triggerEvent('key_equal'); + }, + key_f: function() { + that.triggerEvent('key_f'); + }, + key_g: function() { + that.triggerEvent('key_g'); + }, + key_minus: function() { + that.triggerEvent('key_minus'); + }, + key_n: function() { + that.triggerEvent('key_n'); + }, + key_shift_g: function() { + that.triggerEvent('key_shift_g'); + }, key_space: function() { - that.triggerEvent('paused'); + that.triggerEvent('key_space'); } }) .appendTo( diff --git a/source/Ox.UI/js/Video/Ox.AnnotationPanel.js b/source/Ox.UI/js/Video/Ox.AnnotationPanel.js index d52cc59b..2d69dd20 100644 --- a/source/Ox.UI/js/Video/Ox.AnnotationPanel.js +++ b/source/Ox.UI/js/Video/Ox.AnnotationPanel.js @@ -190,9 +190,6 @@ Ox.AnnotationPanel = function(options, self) { info: function(data) { that.triggerEvent('info', {layer: layer.id}); }, - paused: function() { - that.triggerEvent('paused') - }, remove: function(data) { that.triggerEvent('remove', Ox.extend({layer: layer.id}, data)); }, @@ -221,6 +218,30 @@ Ox.AnnotationPanel = function(options, self) { that.triggerEvent('toggle' + ( layer.type == 'event' ? 'calendar' : 'map' ), data); + }, + key_b: function() { + that.triggerEvent('key_b'); + }, + key_equal: function() { + that.triggerEvent('key_equal'); + }, + key_f: function() { + that.triggerEvent('key_f'); + }, + key_g: function() { + that.triggerEvent('key_g'); + }, + key_minus: function() { + that.triggerEvent('key_minus'); + }, + key_n: function() { + that.triggerEvent('key_n'); + }, + key_shift_g: function() { + that.triggerEvent('key_shift_g'); + }, + key_space: function() { + that.triggerEvent('key_space'); } }) .appendTo(self.$folders); diff --git a/source/Ox.UI/js/Video/Ox.VideoEditor.js b/source/Ox.UI/js/Video/Ox.VideoEditor.js index cd19eebb..788912b3 100644 --- a/source/Ox.UI/js/Video/Ox.VideoEditor.js +++ b/source/Ox.UI/js/Video/Ox.VideoEditor.js @@ -128,7 +128,7 @@ Ox.VideoEditor = function(options, self) { self.options.videoSize == 'large' && toggleSize(); }, key_n: function() { - self.annotations.length && selectAnnotation(getNextAnnotation('annotation', 1), true); + self.annotations.length && selectAnnotation(getNextAnnotation('annotation', 1)); }, key_o: function() { setPoint('out', self.options.position); @@ -620,7 +620,6 @@ Ox.VideoEditor = function(options, self) { info: function(data) { that.triggerEvent('info', data); }, - paused: togglePaused, remove: removeAnnotation, resize: resizeAnnotations, resizeend: resizeendAnnotations, @@ -648,6 +647,30 @@ Ox.VideoEditor = function(options, self) { togglemap: function(data) { self.options.showAnnotationsMap = !data.collapsed; that.triggerEvent('togglemap', data); + }, + key_b: function() { + that.triggerEvent('key_b'); + }, + key_equal: function() { + that.triggerEvent('key_equal'); + }, + key_f: function() { + that.triggerEvent('key_f'); + }, + key_g: function() { + that.triggerEvent('key_g'); + }, + key_minus: function() { + that.triggerEvent('key_minus'); + }, + key_n: function() { + that.triggerEvent('key_n'); + }, + key_shift_g: function() { + that.triggerEvent('key_shift_g'); + }, + key_space: function() { + that.triggerEvent('key_space'); } });