1
0
Fork 0
forked from 0x2620/oxjs

add enableMouse option to VideoPlayer

This commit is contained in:
rlx 2011-08-18 14:03:48 +00:00
commit 9d0dee01e8
5 changed files with 13 additions and 6 deletions

View file

@ -170,6 +170,7 @@ Ox.VideoEditor = function(options, self) {
['play', 'playInToOut', 'volume', 'size', 'space', 'position'] :
['goto', 'set', 'space', 'position'],
duration: self.options.duration,
enableMouse: true,
externalControls: true,
find: self.options.find,
height: self.sizes.player[i].height,

View file

@ -69,6 +69,7 @@ Ox.VideoPanelPlayer = function(options, self) {
controlsBottom: ['play', 'volume', 'timeline', 'position', 'resolution'],
enableFind: true,
enableKeyboard: true,
enableMouse: true,
height: getPlayerHeight(),
muted: self.options.muted,
paused: true,

View file

@ -20,6 +20,7 @@ Ox.VideoPlayer <f> Generic Video Player
enableFind <b|false> If true, enable find
enableFullscreen <b|false> If true, enable fullscreen
enableKeyboard <b|false> If true, enable keyboard controls
enableMouse <b|false> If true, click toggles paused
externalControls <b|false> If true, controls are outside the video
find <s|''> Query string
focus <s|'click'> focus on 'click', 'load' or 'mouseover'
@ -257,7 +258,7 @@ Ox.VideoPlayer = function(options, self) {
if (self.options.type == 'play') {
self.$videoContainer.bind({
self.options.enableMouse && self.$videoContainer.bind({
click: function(e) {
if (!$(e.target).is('.OxLogo')) {
togglePaused();
@ -291,7 +292,7 @@ Ox.VideoPlayer = function(options, self) {
} else {
self.$videoContainer.bind({
self.options.enableMouse && self.$videoContainer.bind({
click: function(e) {
if (!$(e.target).is('.OxLogo')) {
goToPoint();