use new api of oxjs video widgets (timeline types)
This commit is contained in:
parent
750a7965f7
commit
b1c3af091b
4 changed files with 28 additions and 14 deletions
|
@ -24,11 +24,13 @@ pandora.ui.editor = function(data) {
|
||||||
getFrameURL: function(position) {
|
getFrameURL: function(position) {
|
||||||
return '/' + pandora.user.ui.item + '/' + pandora.user.ui.videoResolution + 'p' + position + '.jpg';
|
return '/' + pandora.user.ui.item + '/' + pandora.user.ui.videoResolution + 'p' + position + '.jpg';
|
||||||
},
|
},
|
||||||
getLargeTimelineImageURL: function(i) {
|
getLargeTimelineURL: function(type, i) {
|
||||||
return '/' + pandora.user.ui.item + '/timeline64p' + i + '.png';
|
type = '';
|
||||||
|
return '/' + pandora.user.ui.item + '/timeline' + type + '64p' + i + '.png';
|
||||||
},
|
},
|
||||||
getSmallTimelineImageURL: function(i) {
|
getSmallTimelineURL: function(type, i) {
|
||||||
return '/' + pandora.user.ui.item + '/timeline16p' + i + '.png';
|
type = '';
|
||||||
|
return '/' + pandora.user.ui.item + '/timeline' + type + '16p' + i + '.png';
|
||||||
},
|
},
|
||||||
height: pandora.$ui.contentPanel.size(1),
|
height: pandora.$ui.contentPanel.size(1),
|
||||||
id: 'editor',
|
id: 'editor',
|
||||||
|
@ -54,6 +56,8 @@ pandora.ui.editor = function(data) {
|
||||||
showLayers: Ox.clone(pandora.user.ui.showLayers),
|
showLayers: Ox.clone(pandora.user.ui.showLayers),
|
||||||
showUsers: pandora.site.annotations.showUsers,
|
showUsers: pandora.site.annotations.showUsers,
|
||||||
subtitles: data.subtitles,
|
subtitles: data.subtitles,
|
||||||
|
timeline: pandora.user.ui.videoTimeline,
|
||||||
|
timelines: pandora.site.timelines,
|
||||||
tooltips: true,
|
tooltips: true,
|
||||||
video: data.video,
|
video: data.video,
|
||||||
videoRatio: data.videoRatio,
|
videoRatio: data.videoRatio,
|
||||||
|
@ -216,6 +220,9 @@ pandora.ui.editor = function(data) {
|
||||||
subtitles: function(data) {
|
subtitles: function(data) {
|
||||||
pandora.UI.set('videoSubtitles', data.subtitles);
|
pandora.UI.set('videoSubtitles', data.subtitles);
|
||||||
},
|
},
|
||||||
|
timeline: function(data) {
|
||||||
|
pandora.UI.set('videoTimeline', data.timeline);
|
||||||
|
},
|
||||||
togglecalendar: function(data) {
|
togglecalendar: function(data) {
|
||||||
pandora.UI.set('showAnnotationsCalendar', !data.collapsed);
|
pandora.UI.set('showAnnotationsCalendar', !data.collapsed);
|
||||||
},
|
},
|
||||||
|
|
|
@ -305,8 +305,9 @@ pandora.ui.list = function() {
|
||||||
options: {
|
options: {
|
||||||
duration: data.duration,
|
duration: data.duration,
|
||||||
find: isClipsQuery ? clipsQuery.conditions[0].value : '',
|
find: isClipsQuery ? clipsQuery.conditions[0].value : '',
|
||||||
getImageURL: function(i) {
|
getImageURL: function(type, i) {
|
||||||
return '/' + data.id + '/timeline16p' + i + '.png';
|
type = '';
|
||||||
|
return '/' + data.id + '/timeline' + type + '16p' + i + '.png';
|
||||||
},
|
},
|
||||||
position: pandora.user.ui.videoPoints[data.id]
|
position: pandora.user.ui.videoPoints[data.id]
|
||||||
? pandora.user.ui.videoPoints[data.id].position : 0,
|
? pandora.user.ui.videoPoints[data.id].position : 0,
|
||||||
|
@ -314,9 +315,9 @@ pandora.ui.list = function() {
|
||||||
return {'in': clip['in'], out: clip.out};
|
return {'in': clip['in'], out: clip.out};
|
||||||
}) : [],
|
}) : [],
|
||||||
subtitles: isClipsQuery ? data.clips.map(function(clip) {
|
subtitles: isClipsQuery ? data.clips.map(function(clip) {
|
||||||
Ox.Log('', 'CLIP:::::', clip)
|
|
||||||
return {'in': clip['in'], out: clip.out, text: clip.annotations[0].value};
|
return {'in': clip['in'], out: clip.out, text: clip.annotations[0].value};
|
||||||
}) : []
|
}) : [],
|
||||||
|
type: pandora.user.ui.videoTimeline
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -20,8 +20,9 @@ pandora.ui.player = function(data) {
|
||||||
enableDownload: pandora.site.capabilities.canDownloadVideo[pandora.user.level] >= data.rightslevel,
|
enableDownload: pandora.site.capabilities.canDownloadVideo[pandora.user.level] >= data.rightslevel,
|
||||||
enableSubtitles: pandora.user.ui.videoSubtitles,
|
enableSubtitles: pandora.user.ui.videoSubtitles,
|
||||||
find: pandora.user.ui.itemFind,
|
find: pandora.user.ui.itemFind,
|
||||||
getTimelineImageURL: function(i) {
|
getLargeTimelineURL: function(type, i) {
|
||||||
return '/' + pandora.user.ui.item + '/timeline64p' + i + '.png';
|
type = '';
|
||||||
|
return '/' + pandora.user.ui.item + '/timeline' + type + '64p' + i + '.png';
|
||||||
},
|
},
|
||||||
height: pandora.$ui.contentPanel.size(1),
|
height: pandora.$ui.contentPanel.size(1),
|
||||||
'in': pandora.user.ui.videoPoints[pandora.user.ui.item]['in'],
|
'in': pandora.user.ui.videoPoints[pandora.user.ui.item]['in'],
|
||||||
|
@ -40,9 +41,10 @@ pandora.ui.player = function(data) {
|
||||||
showLayers: Ox.clone(pandora.user.ui.showLayers),
|
showLayers: Ox.clone(pandora.user.ui.showLayers),
|
||||||
showUsers: pandora.site.annotations.showUsers,
|
showUsers: pandora.site.annotations.showUsers,
|
||||||
showTimeline: pandora.user.ui.showTimeline,
|
showTimeline: pandora.user.ui.showTimeline,
|
||||||
|
smallTimelineURL: '/' + pandora.user.ui.item + '/timeline16p.png',
|
||||||
subtitles: data.subtitles,
|
subtitles: data.subtitles,
|
||||||
|
timeline: pandora.user.ui.videoTimeline,
|
||||||
tooltips: true,
|
tooltips: true,
|
||||||
timeline: '/' + pandora.user.ui.item + '/timeline16p.png',
|
|
||||||
video: data.video,
|
video: data.video,
|
||||||
volume: pandora.user.ui.videoVolume,
|
volume: pandora.user.ui.videoVolume,
|
||||||
width: pandora.$ui.document.width() - pandora.$ui.mainPanel.size(0) - 1
|
width: pandora.$ui.document.width() - pandora.$ui.mainPanel.size(0) - 1
|
||||||
|
|
|
@ -21,8 +21,9 @@ pandora.ui.timeline = function(data) {
|
||||||
getFrameURL: function(position) {
|
getFrameURL: function(position) {
|
||||||
return '/' + ui.item + '/' + ui.videoResolution + 'p' + position + '.jpg';
|
return '/' + ui.item + '/' + ui.videoResolution + 'p' + position + '.jpg';
|
||||||
},
|
},
|
||||||
getTimelineImageURL: function(i) {
|
getLargeTimelineURL: function(type, i) {
|
||||||
return '/' + ui.item + '/timeline64p' + i + '.png';
|
type = '';
|
||||||
|
return '/' + ui.item + '/timeline' + type + '64p' + i + '.png';
|
||||||
},
|
},
|
||||||
height: pandora.$ui.contentPanel.size(1),
|
height: pandora.$ui.contentPanel.size(1),
|
||||||
layers: data.annotations,
|
layers: data.annotations,
|
||||||
|
@ -37,8 +38,8 @@ pandora.ui.timeline = function(data) {
|
||||||
showAnnotationsMap: ui.showAnnotationsMap,
|
showAnnotationsMap: ui.showAnnotationsMap,
|
||||||
showLayers: Ox.clone(ui.showLayers),
|
showLayers: Ox.clone(ui.showLayers),
|
||||||
showUsers: pandora.site.annotations.showUsers,
|
showUsers: pandora.site.annotations.showUsers,
|
||||||
|
smallTimelineURL: '/' + ui.item + '/timeline16p.png',
|
||||||
timeline: ui.videoTimeline,
|
timeline: ui.videoTimeline,
|
||||||
timelineImageURL: '/' + ui.item + '/timeline16p.png',
|
|
||||||
timelines: pandora.site.timelines,
|
timelines: pandora.site.timelines,
|
||||||
video: data.video,
|
video: data.video,
|
||||||
videoRatio: data.videoRatio,
|
videoRatio: data.videoRatio,
|
||||||
|
@ -82,6 +83,9 @@ pandora.ui.timeline = function(data) {
|
||||||
select: function(data) {
|
select: function(data) {
|
||||||
pandora.UI.set('videoPoints.' + pandora.user.ui.item + '.annotation', data.id.split('/')[1]);
|
pandora.UI.set('videoPoints.' + pandora.user.ui.item + '.annotation', data.id.split('/')[1]);
|
||||||
},
|
},
|
||||||
|
timeline: function(data) {
|
||||||
|
pandora.UI.set('videoTimeline', data.timeline);
|
||||||
|
},
|
||||||
toggleannotations: function(data) {
|
toggleannotations: function(data) {
|
||||||
pandora.UI.set('showAnnotations', data.showAnnotations);
|
pandora.UI.set('showAnnotations', data.showAnnotations);
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in a new issue