update video editor (places, events)
This commit is contained in:
parent
265d3d5bcd
commit
81548bba04
4 changed files with 18 additions and 2 deletions
|
@ -103,10 +103,14 @@ class Annotation(models.Model):
|
||||||
|
|
||||||
if filter(lambda l: l['type'] == 'place' or l.get('hasPlaces'),
|
if filter(lambda l: l['type'] == 'place' or l.get('hasPlaces'),
|
||||||
settings.CONFIG['layers']):
|
settings.CONFIG['layers']):
|
||||||
update_matching_places.delay(self.id)
|
#update_matching_places.delay(self.id)
|
||||||
|
#editAnnotations needs to be in snyc
|
||||||
|
update_matching_places(self.id)
|
||||||
if filter(lambda l: l['type'] == 'event' or l.get('hasEvents'),
|
if filter(lambda l: l['type'] == 'event' or l.get('hasEvents'),
|
||||||
settings.CONFIG['layers']):
|
settings.CONFIG['layers']):
|
||||||
update_matching_events.delay(self.id)
|
#update_matching_events.delay(self.id)
|
||||||
|
#editAnnotations needs to be in snyc
|
||||||
|
update_matching_events(self.id)
|
||||||
|
|
||||||
def json(self, layer=False, keys=None, user=None):
|
def json(self, layer=False, keys=None, user=None):
|
||||||
j = {
|
j = {
|
||||||
|
|
|
@ -517,7 +517,9 @@
|
||||||
"user": {
|
"user": {
|
||||||
"level": "guest",
|
"level": "guest",
|
||||||
"ui": {
|
"ui": {
|
||||||
|
"annotationsCalendarSize": 256,
|
||||||
"annotationsFont": "small",
|
"annotationsFont": "small",
|
||||||
|
"annotationsMapSize": 256,
|
||||||
"annotationsRange": "position",
|
"annotationsRange": "position",
|
||||||
"annotationsSize": 256,
|
"annotationsSize": 256,
|
||||||
"annotationsSort": "position",
|
"annotationsSort": "position",
|
||||||
|
@ -555,6 +557,8 @@
|
||||||
"page": "",
|
"page": "",
|
||||||
"section": "items",
|
"section": "items",
|
||||||
"showAnnotations": true,
|
"showAnnotations": true,
|
||||||
|
"showAnnotationsCalendar": true,
|
||||||
|
"showAnnotationsMap": true,
|
||||||
"showBrowser": true,
|
"showBrowser": true,
|
||||||
"showCalendarControls": true, // fixme: should be false
|
"showCalendarControls": true, // fixme: should be false
|
||||||
"showFilters": true,
|
"showFilters": true,
|
||||||
|
|
|
@ -218,7 +218,9 @@ pandora.ui.item = function() {
|
||||||
} else if (pandora.user.ui.itemView == 'timeline') {
|
} else if (pandora.user.ui.itemView == 'timeline') {
|
||||||
pandora.$ui.contentPanel.replaceElement(1,
|
pandora.$ui.contentPanel.replaceElement(1,
|
||||||
pandora.$ui.editor = Ox.VideoEditor({
|
pandora.$ui.editor = Ox.VideoEditor({
|
||||||
|
annotationsCalendarSize: pandora.user.ui.annotationsCalendarSize,
|
||||||
annotationsFont: pandora.user.ui.annotationsFont,
|
annotationsFont: pandora.user.ui.annotationsFont,
|
||||||
|
annotationsMapSize: pandora.user.ui.annotationsMapSize,
|
||||||
annotationsRange: pandora.user.ui.annotationsRange,
|
annotationsRange: pandora.user.ui.annotationsRange,
|
||||||
annotationsSize: pandora.user.ui.annotationsSize,
|
annotationsSize: pandora.user.ui.annotationsSize,
|
||||||
annotationsSort: pandora.user.ui.annotationsSort,
|
annotationsSort: pandora.user.ui.annotationsSort,
|
||||||
|
@ -254,6 +256,8 @@ pandora.ui.item = function() {
|
||||||
? pandora.user.ui.item + '/' + pandora.user.ui.videoPoints[pandora.user.ui.item].annotation
|
? pandora.user.ui.item + '/' + pandora.user.ui.videoPoints[pandora.user.ui.item].annotation
|
||||||
: '',
|
: '',
|
||||||
showAnnotations: pandora.user.ui.showAnnotations,
|
showAnnotations: pandora.user.ui.showAnnotations,
|
||||||
|
showAnnotationsCalendar: pandora.user.ui.showAnnotationsCalendar,
|
||||||
|
showAnnotationsMap: pandora.user.ui.showAnnotationsMap,
|
||||||
showLargeTimeline: true,
|
showLargeTimeline: true,
|
||||||
showLayers: pandora.user.ui.showLayers,
|
showLayers: pandora.user.ui.showLayers,
|
||||||
showUsers: pandora.site.annotations.showUsers,
|
showUsers: pandora.site.annotations.showUsers,
|
||||||
|
@ -344,6 +348,8 @@ pandora.ui.item = function() {
|
||||||
value: data.value,
|
value: data.value,
|
||||||
}, function(result) {
|
}, function(result) {
|
||||||
Ox.Log('', 'editAnnotation result', result);
|
Ox.Log('', 'editAnnotation result', result);
|
||||||
|
result.data.duration = result.data.out - result.data['in'];
|
||||||
|
pandora.$ui.editor.updateAnnotation(data.layer, result.data);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
removeannotation: function(data) {
|
removeannotation: function(data) {
|
||||||
|
|
|
@ -165,6 +165,8 @@ pandora.ui.navigationView = function(type, videoRatio) {
|
||||||
height: window.innerHeight - ui.showFilters * ui.filtersSize - 61,
|
height: window.innerHeight - ui.showFilters * ui.filtersSize - 61,
|
||||||
range: [-5000, 5000],
|
range: [-5000, 5000],
|
||||||
showControls: ui.showCalendarControls,
|
showControls: ui.showCalendarControls,
|
||||||
|
showToolbar: true,
|
||||||
|
showZoombar: true,
|
||||||
width: window.innerWidth - ui.showSidebar * ui.sidebarSize - listSize - 2,
|
width: window.innerWidth - ui.showSidebar * ui.sidebarSize - listSize - 2,
|
||||||
zoom: 4
|
zoom: 4
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue