equal
deleted
inserted
replaced
170 * Est appelé : dans le fichier pointers > fonction pointersVideoInteractions. |
170 * Est appelé : dans le fichier pointers > fonction pointersVideoInteractions. |
171 */ |
171 */ |
172 Mosaic.prototype.selectNeighbour = function(neighbour, pointer) |
172 Mosaic.prototype.selectNeighbour = function(neighbour, pointer) |
173 { |
173 { |
174 //Si on est en train de se déplacer vers un voisin ou dézoomer ou si l'aide est affichée, on part. |
174 //Si on est en train de se déplacer vers un voisin ou dézoomer ou si l'aide est affichée, on part. |
175 if(this.currentlyMoving || this.currentlyUnzooming || this.helpDisplayed) |
175 if(this.currentlyMoving || this.currentlyUnzooming || this.helpDisplayed || this.isSearchByCurvesOn) |
176 { |
176 { |
177 return; |
177 return; |
178 } |
178 } |
179 |
179 |
|
180 if(this.config.mouseInteractions) |
|
181 { |
|
182 this.canMoveToNeighbour = true; |
|
183 } |
|
184 |
180 //Si on est sur une notification de gesture de recherche. |
185 //Si on est sur une notification de gesture de recherche. |
181 if(this.gestureDelRequested) |
186 if(this.gestureDelRequested) |
182 { |
187 { |
183 //On récupère l'id du voisin. |
188 //On récupère l'id du voisin. |
184 var tab = neighbour.attr('id').split('-'); |
189 var tab = neighbour.attr('id').split('-'); |
350 } |
355 } |
351 |
356 |
352 var _this = this; |
357 var _this = this; |
353 |
358 |
354 //On ne peut plus se déplacer vers les voisins. |
359 //On ne peut plus se déplacer vers les voisins. |
355 this.canMoveToNeighbour = true; |
360 if(this.config.mouseInteractions) |
|
361 { |
|
362 this.canMoveToNeighbour = false; |
|
363 } |
|
364 else |
|
365 { |
|
366 this.canMoveToNeighbour = true; |
|
367 } |
356 |
368 |
357 //On récupère le voisin. |
369 //On récupère le voisin. |
358 var neighbourFrame = $('#neighbourFrame-' + neighbourId); |
370 var neighbourFrame = $('#neighbourFrame-' + neighbourId); |
359 |
371 |
360 //Si on est en mode VIDEO. |
372 //Si on est en mode VIDEO. |
426 if(idx > -1 && idx < 4) |
438 if(idx > -1 && idx < 4) |
427 { |
439 { |
428 this.moveToNeighbour($('#snapshotDiv-' + this.neighboursIds[idx])); |
440 this.moveToNeighbour($('#snapshotDiv-' + this.neighboursIds[idx])); |
429 } |
441 } |
430 } |
442 } |
431 else |
443 else if(this.config.mouseInteractions) |
432 { |
444 { |
433 if(idx == 0 && x > centerWidth || idx == 2 && y > centerHeight || idx == 1 && x < centerWidth || idx == 3 && y < centerHeight) |
445 if(idx == 0 && x > centerWidth || idx == 2 && y > centerHeight || idx == 1 && x < centerWidth || idx == 3 && y < centerHeight) |
434 { |
446 { |
435 this.moveToNeighbour($('#snapshotDiv-' + this.neighboursIds[idx])); |
447 this.moveToNeighbour($('#snapshotDiv-' + this.neighboursIds[idx])); |
436 } |
448 } |
500 $('img', _this.previousZoomedSN).attr('src', currentImgSrc.replace('snapshots/', 'snapshots-little/')); |
512 $('img', _this.previousZoomedSN).attr('src', currentImgSrc.replace('snapshots/', 'snapshots-little/')); |
501 |
513 |
502 $('#snapshotDiv-' + destinationId).css('opacity', '1'); |
514 $('#snapshotDiv-' + destinationId).css('opacity', '1'); |
503 |
515 |
504 //Si le player est prêt. |
516 //Si le player est prêt. |
505 if(_this.player && _this.player.widgets[0] && _this.playerIsReady) |
517 if(_this.player && _this.player.widgets && _this.player.widgets[0] && _this.playerIsReady) |
506 { |
518 { |
507 //Si on est en mode timeline on la quitte. |
519 //Si on est en mode timeline on la quitte. |
508 if(_this.currentMode == 'TIMELINE') |
520 if(_this.currentMode == 'TIMELINE') |
509 { |
521 { |
510 _this.exitTimeline('move'); |
522 _this.exitTimeline('move'); |
523 _this.timeToGoAt[_this.centerId] = Math.floor(_this.player.popcorn.currentTime()); |
535 _this.timeToGoAt[_this.centerId] = Math.floor(_this.player.popcorn.currentTime()); |
524 } |
536 } |
525 //On libère le player. |
537 //On libère le player. |
526 _this.player.widgets[0].freePlayer(); |
538 _this.player.widgets[0].freePlayer(); |
527 _this.playerIsReady = false; |
539 _this.playerIsReady = false; |
|
540 _this.isVideoReading = false; |
528 $('.LdtPlayer').remove(); |
541 $('.LdtPlayer').remove(); |
529 |
542 |
530 } |
543 } |
531 |
544 |
532 //On obtient l'ID du div de coloration du snapshot vers lequel on se déplace afin de le supprimer. |
545 //On obtient l'ID du div de coloration du snapshot vers lequel on se déplace afin de le supprimer. |