add annotations view to edits
This commit is contained in:
parent
e3919a72ed
commit
eac549224e
2 changed files with 68 additions and 1 deletions
|
@ -5,16 +5,28 @@ Ox.ClipPanel = function(options, self) {
|
||||||
self = self || {};
|
self = self || {};
|
||||||
var that = Ox.Element({}, self)
|
var that = Ox.Element({}, self)
|
||||||
.defaults({
|
.defaults({
|
||||||
|
annotationsCalendarSize: 256,
|
||||||
|
annotationsFont: 'small',
|
||||||
|
annotationsMapSize: 256,
|
||||||
|
annotationsRange: 'all',
|
||||||
|
annotationsSize: 256,
|
||||||
|
annotationsSort: 'position',
|
||||||
clips: [],
|
clips: [],
|
||||||
|
clickLink: null,
|
||||||
duration: 0,
|
duration: 0,
|
||||||
editable: false,
|
editable: false,
|
||||||
getClipImageURL: null,
|
getClipImageURL: null,
|
||||||
'in': 0,
|
'in': 0,
|
||||||
|
layers: [],
|
||||||
out: 0,
|
out: 0,
|
||||||
position: 0,
|
position: 0,
|
||||||
selected: [],
|
selected: [],
|
||||||
sort: [],
|
sort: [],
|
||||||
sortOptions: [],
|
sortOptions: [],
|
||||||
|
showAnnotationsCalendar: false,
|
||||||
|
showAnnotationsMap: false,
|
||||||
|
showLayers: {},
|
||||||
|
showUsers: false,
|
||||||
view: 'list',
|
view: 'list',
|
||||||
width: 0
|
width: 0
|
||||||
})
|
})
|
||||||
|
@ -32,6 +44,13 @@ Ox.ClipPanel = function(options, self) {
|
||||||
height: function() {
|
height: function() {
|
||||||
self.$list.size();
|
self.$list.size();
|
||||||
},
|
},
|
||||||
|
position: function() {
|
||||||
|
if (self.options.view == 'annotations') {
|
||||||
|
self.$list.options({
|
||||||
|
position: self.options.position
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
selected: selectClips,
|
selected: selectClips,
|
||||||
sort: function() {
|
sort: function() {
|
||||||
updateSortElement();
|
updateSortElement();
|
||||||
|
@ -63,6 +82,7 @@ Ox.ClipPanel = function(options, self) {
|
||||||
{group: 'view', min: 1, max: 1, items: [
|
{group: 'view', min: 1, max: 1, items: [
|
||||||
{id: 'list', title: Ox._('View as List'), checked: self.options.view == 'list'},
|
{id: 'list', title: Ox._('View as List'), checked: self.options.view == 'list'},
|
||||||
{id: 'grid', title: Ox._('View as Grid'), checked: self.options.view == 'grid'},
|
{id: 'grid', title: Ox._('View as Grid'), checked: self.options.view == 'grid'},
|
||||||
|
{id: 'annotations', title: Ox._('View Annotations'), checked: self.options.view == 'annotations'},
|
||||||
]},
|
]},
|
||||||
{},
|
{},
|
||||||
{id: 'split', title: Ox._('Split Selected Clips at Cuts'), disabled: !self.options.editable || !self.options.selected.length},
|
{id: 'split', title: Ox._('Split Selected Clips at Cuts'), disabled: !self.options.editable || !self.options.selected.length},
|
||||||
|
@ -200,7 +220,31 @@ Ox.ClipPanel = function(options, self) {
|
||||||
|
|
||||||
function getList() {
|
function getList() {
|
||||||
var $list;
|
var $list;
|
||||||
if (self.options.view == 'list') {
|
if (self.options.view == 'annotations') {
|
||||||
|
console.log('getList Annotations', self.options.layers);
|
||||||
|
$list = Ox.AnnotationPanel({
|
||||||
|
calendarSize: self.options.annotationsCalendarSize,
|
||||||
|
clickLink: self.options.clickLink,
|
||||||
|
editable: false,
|
||||||
|
font: self.options.annotationsFont,
|
||||||
|
//highlight: self.options.find,
|
||||||
|
//'in': self.options['in'],
|
||||||
|
//itemName: self.options.itemName,
|
||||||
|
layers: self.options.layers,
|
||||||
|
mapSize: self.options.annotationsMapSize,
|
||||||
|
//out: self.options.out,
|
||||||
|
position: self.options.position,
|
||||||
|
range: self.options.annotationsRange,
|
||||||
|
showCalendar: self.options.showAnnotationsCalendar,
|
||||||
|
showLayers: Ox.clone(self.options.showLayers),
|
||||||
|
showMap: self.options.showAnnotationsMap,
|
||||||
|
showUsers: self.options.showUsers,
|
||||||
|
sort: self.options.annotationsSort,
|
||||||
|
width: self.options.annotationsSize
|
||||||
|
});
|
||||||
|
|
||||||
|
return $list;
|
||||||
|
} else if (self.options.view == 'list') {
|
||||||
$list = Ox.TableList({
|
$list = Ox.TableList({
|
||||||
columns: [
|
columns: [
|
||||||
{
|
{
|
||||||
|
|
|
@ -5,6 +5,12 @@ Ox.VideoEditPanel = function(options, self) {
|
||||||
self = self || {};
|
self = self || {};
|
||||||
var that = Ox.Element({}, self)
|
var that = Ox.Element({}, self)
|
||||||
.defaults({
|
.defaults({
|
||||||
|
annotationsCalendarSize: 256,
|
||||||
|
annotationsFont: 'small',
|
||||||
|
annotationsMapSize: 256,
|
||||||
|
annotationsRange: 'all',
|
||||||
|
annotationsSize: 256,
|
||||||
|
annotationsSort: 'position',
|
||||||
clips: [],
|
clips: [],
|
||||||
clipSize: 256,
|
clipSize: 256,
|
||||||
clipSort: [],
|
clipSort: [],
|
||||||
|
@ -22,6 +28,7 @@ Ox.VideoEditPanel = function(options, self) {
|
||||||
height: 0,
|
height: 0,
|
||||||
'in': 0,
|
'in': 0,
|
||||||
loop: false,
|
loop: false,
|
||||||
|
layers: [],
|
||||||
muted: false,
|
muted: false,
|
||||||
out: 0,
|
out: 0,
|
||||||
paused: true,
|
paused: true,
|
||||||
|
@ -30,8 +37,12 @@ Ox.VideoEditPanel = function(options, self) {
|
||||||
resolution: 0,
|
resolution: 0,
|
||||||
scaleToFill: false,
|
scaleToFill: false,
|
||||||
selected: [],
|
selected: [],
|
||||||
|
showAnnotationsCalendar: false,
|
||||||
|
showAnnotationsMap: false,
|
||||||
showClips: false,
|
showClips: false,
|
||||||
|
showLayers: {},
|
||||||
showTimeline: false,
|
showTimeline: false,
|
||||||
|
showUsers: false,
|
||||||
smallTimelineURL: '',
|
smallTimelineURL: '',
|
||||||
subtitles: [],
|
subtitles: [],
|
||||||
timeline: '',
|
timeline: '',
|
||||||
|
@ -283,14 +294,26 @@ Ox.VideoEditPanel = function(options, self) {
|
||||||
});
|
});
|
||||||
|
|
||||||
self.$clipPanel = Ox.ClipPanel({
|
self.$clipPanel = Ox.ClipPanel({
|
||||||
|
annotationsCalendarSize: self.options.annotationsCalendarSize,
|
||||||
|
annotationsFont: self.options.annotationsFont,
|
||||||
|
annotationsMapSize: self.options.annotationsMapSize,
|
||||||
|
annotationsRange: self.options.annotationsRange,
|
||||||
|
annotationsSize: self.options.annotationsSize,
|
||||||
|
annotationsSort: self.options.annotationsSort,
|
||||||
clips: Ox.clone(self.options.clips),
|
clips: Ox.clone(self.options.clips),
|
||||||
|
clickLink: self.options.clickLink,
|
||||||
duration: self.options.duration,
|
duration: self.options.duration,
|
||||||
editable: self.options.editable,
|
editable: self.options.editable,
|
||||||
getClipImageURL: self.options.getClipImageURL,
|
getClipImageURL: self.options.getClipImageURL,
|
||||||
'in': self.options['in'],
|
'in': self.options['in'],
|
||||||
|
layers: Ox.clone(self.options.layers),
|
||||||
out: self.options.out,
|
out: self.options.out,
|
||||||
position: self.options.position,
|
position: self.options.position,
|
||||||
selected: self.options.selected,
|
selected: self.options.selected,
|
||||||
|
showAnnotationsCalendar: self.options.showAnnotationsCalendar,
|
||||||
|
showAnnotationsMap: self.options.showAnnotationsMap,
|
||||||
|
showLayers: self.options.showLayers,
|
||||||
|
showUsers: self.options.showUsers,
|
||||||
sort: self.options.clipSort,
|
sort: self.options.clipSort,
|
||||||
sortOptions: self.options.sortOptions,
|
sortOptions: self.options.sortOptions,
|
||||||
view: self.options.clipView,
|
view: self.options.clipView,
|
||||||
|
|
Loading…
Reference in a new issue