forked from 0x2620/oxjs
rename various options of video widgets to allow for different timeline types
This commit is contained in:
parent
baa9e9be61
commit
132e8d2207
10 changed files with 90 additions and 67 deletions
|
|
@ -34,8 +34,8 @@ Ox.VideoEditor = function(options, self) {
|
|||
find: '',
|
||||
fps: 25,
|
||||
getFrameURL: null,
|
||||
getLargeTimelineImageURL: null,
|
||||
getSmallTimelineImageURL: null,
|
||||
getLargeTimelineURL: null,
|
||||
getSmallTimelineURL: null,
|
||||
'in': 0,
|
||||
height: 0,
|
||||
layers: [],
|
||||
|
|
@ -53,6 +53,8 @@ Ox.VideoEditor = function(options, self) {
|
|||
showLayers: {},
|
||||
showUsers: false,
|
||||
subtitles: [],
|
||||
timeline: '',
|
||||
timelines: [],
|
||||
tooltips: false,
|
||||
videoRatio: 16/9,
|
||||
videoSize: 'small',
|
||||
|
|
@ -300,14 +302,14 @@ Ox.VideoEditor = function(options, self) {
|
|||
cuts: self.options.cuts,
|
||||
duration: self.options.duration,
|
||||
find: self.options.find,
|
||||
getImageURL: self.options.getLargeTimelineImageURL,
|
||||
getImageURL: self.options.getLargeTimelineURL,
|
||||
id: 'timelineLarge',
|
||||
'in': self.options['in'],
|
||||
//matches: self.options.matches,
|
||||
out: self.options.out,
|
||||
position: self.options.position,
|
||||
subtitles: self.options.enableSubtitles ? self.options.subtitles : [],
|
||||
type: 'editor',
|
||||
type: self.options.timeline,
|
||||
width: self.sizes.timeline[0].width
|
||||
})
|
||||
.css({
|
||||
|
|
@ -325,7 +327,7 @@ Ox.VideoEditor = function(options, self) {
|
|||
cuts: self.options.cuts,
|
||||
duration: self.options.duration,
|
||||
find: self.options.find,
|
||||
getImageURL: self.options.getSmallTimelineImageURL,
|
||||
getImageURL: self.options.getSmallTimelineURL,
|
||||
id: 'timelineSmall',
|
||||
'in': self.options['in'],
|
||||
out: self.options.out,
|
||||
|
|
@ -334,6 +336,7 @@ Ox.VideoEditor = function(options, self) {
|
|||
showPointMarkers: true,
|
||||
state: self.options.selected ? 'selected' : 'default',
|
||||
subtitles: self.options.enableSubtitles ? self.options.subtitles : [],
|
||||
type: self.options.timeline,
|
||||
videoId: self.options.videoId,
|
||||
width: self.sizes.timeline[1].width
|
||||
})
|
||||
|
|
@ -432,10 +435,7 @@ Ox.VideoEditor = function(options, self) {
|
|||
self.$menuButton = Ox.MenuButton({
|
||||
items: Ox.merge(
|
||||
[
|
||||
{group: 'size', min: 1, max: 1, items: [
|
||||
{id: 'small', title: 'Small Player', checked: self.options.videoSize == 'small'},
|
||||
{id: 'large', title: 'Large Player', checked: self.options.videoSize == 'large'}
|
||||
]},
|
||||
{id: 'size', title: 'Large Player', checked: self.options.videoSize == 'large'},
|
||||
{},
|
||||
{group: 'resolution', min: 1, max: 1, items: self.resolutions}
|
||||
],
|
||||
|
|
@ -444,6 +444,17 @@ Ox.VideoEditor = function(options, self) {
|
|||
{id: 'subtitles', title: 'Show Subtitles', checked: self.options.enableSubtitles}
|
||||
] : [],
|
||||
[
|
||||
{},
|
||||
{id: 'timelines', title: 'Timeline', disabled: true},
|
||||
{group: 'timeline', min: 1, max: 1, items: Ox.map(
|
||||
self.options.timelines,
|
||||
function(timeline) {
|
||||
return Ox.extend({
|
||||
checked: timeline.id == self.options.timeline,
|
||||
disabled: true
|
||||
}, timeline);
|
||||
}
|
||||
)},
|
||||
{},
|
||||
{id: 'downloadVideo', title: 'Download Video...', disabled: !self.options.enableDownload },
|
||||
{id: 'downloadSelection', title: 'Download Selection...', disabled: !self.options.enableDownload},
|
||||
|
|
@ -465,7 +476,7 @@ Ox.VideoEditor = function(options, self) {
|
|||
),
|
||||
style: 'square',
|
||||
title: 'set',
|
||||
tooltip: 'Actions and Settings',
|
||||
tooltip: 'Options',
|
||||
type: 'image'
|
||||
})
|
||||
.css({float: 'left'})
|
||||
|
|
@ -509,6 +520,8 @@ Ox.VideoEditor = function(options, self) {
|
|||
toggleSize();
|
||||
} else if (id == 'subtitles') {
|
||||
toggleSubtitles();
|
||||
} else if (id == 'timeline') {
|
||||
// data.checked[0].id
|
||||
}
|
||||
},
|
||||
hide: function() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue