diff --git a/source/UI/js/Video/VideoAnnotationPanel.js b/source/UI/js/Video/VideoAnnotationPanel.js index 4700b283..a3935b1e 100644 --- a/source/UI/js/Video/VideoAnnotationPanel.js +++ b/source/UI/js/Video/VideoAnnotationPanel.js @@ -237,7 +237,9 @@ Ox.VideoAnnotationPanel = function(options, self) { setPoint('in', self.options.position); }, key_k: function togglePlaybackRate() { - that.options({playbackRate: self.options.playbackRate == 1 ? 2 : 1}); + that.options({ + playbackRate: self.options.playbackRate == 1 ? 2 : self.options.playbackRate == 2 ? 0.5 : 1 + }); }, key_l: toggleLoop, key_left: function() { diff --git a/source/UI/js/Video/VideoPlayer.js b/source/UI/js/Video/VideoPlayer.js index 0ffaab2b..36c2822b 100644 --- a/source/UI/js/Video/VideoPlayer.js +++ b/source/UI/js/Video/VideoPlayer.js @@ -321,6 +321,11 @@ Ox.VideoPlayer = function(options, self) { key_g: function() { goToNext('result', 1); }, + key_k: function togglePlaybackRate() { + that.options({ + playbackRate: self.options.playbackRate == 1 ? 2 : self.options.playbackRate == 2 ? 0.5 : 1 + }); + }, key_l: toggleLoop, key_left: function() { setPosition(self.options.position - self.secondsPerFrame); diff --git a/source/UI/js/Video/VideoPlayerPanel.js b/source/UI/js/Video/VideoPlayerPanel.js index d59d4862..1b376d81 100644 --- a/source/UI/js/Video/VideoPlayerPanel.js +++ b/source/UI/js/Video/VideoPlayerPanel.js @@ -16,6 +16,7 @@ Ox.VideoPlayerPanel VideoPlayerPanel Object key_* key_* muted muted paused paused + playbackRate: playback rate position position resizecalendar resizecalendar resolution resolution @@ -62,6 +63,7 @@ Ox.VideoPlayerPanel = function(options, self) { muted: false, out: 0, paused: true, + playbackRate: 1, playInToOut: false, position: 0, poster: '', @@ -106,6 +108,11 @@ Ox.VideoPlayerPanel = function(options, self) { paused: function() { self.$video.options({paused: self.options.paused}); }, + playbackRate: function() { + self.$video.options({ + playbackRate: self.options.playbackRate + }); + }, position: function() { self.$video.options({position: self.options.position}); self.$timeline.options({position: self.options.position}); @@ -167,6 +174,11 @@ Ox.VideoPlayerPanel = function(options, self) { self.$annotationPanel.options({selected: ''}); setPoint('in', self.options.position, false, true); }, + key_k: function togglePlaybackRate() { + that.options({ + playbackRate: self.options.playbackRate == 1 ? 2 : self.options.playbackRate == 2 ? 0.5 : 1 + }); + }, key_l: toggleLoop, key_left: function() { movePositionBy(-1 / self.options.fps);