remove subtitles.sort from 0xdb config, duration should always be >=0
This commit is contained in:
parent
f3d20abe99
commit
fbe8c9160b
3 changed files with 2 additions and 6 deletions
|
@ -540,10 +540,6 @@
|
||||||
"hasPlaces": true,
|
"hasPlaces": true,
|
||||||
"item": "Subtitle",
|
"item": "Subtitle",
|
||||||
"overlay": true,
|
"overlay": true,
|
||||||
"sort": [
|
|
||||||
{"id": "words", "title": "Words", "type": "words"},
|
|
||||||
{"id": "wordsperminute", "title": "Words per Minute", "type": "wordsperminute"}
|
|
||||||
],
|
|
||||||
"type": "text"
|
"type": "text"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
|
@ -188,7 +188,7 @@ class Annotation(models.Model):
|
||||||
'saturation': 'clip__saturation',
|
'saturation': 'clip__saturation',
|
||||||
'volume': 'clip__volume',
|
'volume': 'clip__volume',
|
||||||
}.get(key, key))
|
}.get(key, key))
|
||||||
j['duration'] = j['out'] - j['in']
|
j['duration'] = abs(j['out'] - j['in'])
|
||||||
if user:
|
if user:
|
||||||
j['editable'] = self.editable(user)
|
j['editable'] = self.editable(user)
|
||||||
|
|
||||||
|
|
|
@ -803,7 +803,7 @@ pandora.getVideoOptions = function(data) {
|
||||||
pandora.site.layers.forEach(function(layer, i) {
|
pandora.site.layers.forEach(function(layer, i) {
|
||||||
options.layers[i] = Ox.extend({}, layer, {
|
options.layers[i] = Ox.extend({}, layer, {
|
||||||
items: data.layers[layer.id].map(function(annotation) {
|
items: data.layers[layer.id].map(function(annotation) {
|
||||||
annotation.duration = annotation.out - annotation['in'];
|
annotation.duration = Math.abs(annotation.out - annotation['in']);
|
||||||
annotation.editable = annotation.editable
|
annotation.editable = annotation.editable
|
||||||
|| annotation.user == pandora.user.username
|
|| annotation.user == pandora.user.username
|
||||||
|| pandora.site.capabilities['canEditAnnotations'][pandora.user.level];
|
|| pandora.site.capabilities['canEditAnnotations'][pandora.user.level];
|
||||||
|
|
Loading…
Reference in a new issue