Compare commits

..

No commits in common. "c2d35e615defb9b7d814d637bb330af77380f956" and "290afaf332be1e84e2bf66551546af164edffda6" have entirely different histories.

2 changed files with 10 additions and 10 deletions

View file

@ -325,7 +325,7 @@ Ox.AnnotationFolder = function(options, self) {
that.triggerEvent('add', {value: data.value || ''});
},
blur: function(data) {
if (data && data.id && data.id[0] == '_') {
if (data && data.id[0] == '_') {
changeAnnotation(data);
that.triggerEvent('blur');
} else {

View file

@ -938,7 +938,7 @@ Ox.VideoAnnotationPanel = function(options, self) {
that.triggerEvent('resizemap', data);
},
select: function(data) {
selectAnnotation(data, !self.updating);
selectAnnotation(data, true);
},
showentityinfo: function(data) {
that.triggerEvent('showentityinfo', data);
@ -1340,7 +1340,7 @@ Ox.VideoAnnotationPanel = function(options, self) {
that.triggerEvent('annotationssize', {size: data.size});
}
function selectAnnotation(data, moveToPosition) {
function selectAnnotation(data, stayAtPosition) {
if (Ox.isUndefined(data)) {
// doubleclick on small timeline
data = getAnnotation();
@ -1351,11 +1351,13 @@ Ox.VideoAnnotationPanel = function(options, self) {
// FIXME
// self.editing = false;
if (data.id) {
var outOfRange = self.options.annotationsRange != 'position' && (
self.options.position < data['in']
|| self.options.position > data.out
)
if (moveToPosition && outOfRange) {
if (!stayAtPosition || (
self.options.annotationsRange != 'position' && (
self.options.position < data['in']
|| self.options.position > data.out
)
)
) {
setPosition(data['in']);
// if annotationsRange is 'position',
// this may cause a deselect
@ -1715,7 +1717,6 @@ Ox.VideoAnnotationPanel = function(options, self) {
(id, annotation) -> <o> update annotation with id
@*/
that.updateAnnotation = function(id, annotation) {
self.updating = true
// called from editannotation callback
// id might have changed if new annotation was created
if (annotation.id) {
@ -1729,7 +1730,6 @@ Ox.VideoAnnotationPanel = function(options, self) {
self.annotations = getAnnotations();
setTimelineState();
}
self.updating = false
};
/*@