803 var currentPicto = notification_search.css('background-image'); |
803 var currentPicto = notification_search.css('background-image'); |
804 |
804 |
805 //Si le pointeur est sur la notification. |
805 //Si le pointeur est sur la notification. |
806 if(x > notification_search.position().left && x < (+notification_search.position().left + notification_search.width()) && y > notification_search.position().top && y < (+notification_search.position().top + notification_search.height())) |
806 if(x > notification_search.position().left && x < (+notification_search.position().left + notification_search.width()) && y > notification_search.position().top && y < (+notification_search.position().top + notification_search.height())) |
807 { |
807 { |
808 if(!this.alreadyOnNotification && ($('#spinner').length == 0 && !this.config.mouseInteractions || this.config.mouseInteractions)) |
808 if(!this.alreadyOnNotification && ($('#spinner').length == 0 && !this.config.mouseInteractions || this.config.mouseInteractions) && !this.isTablet) |
809 { |
809 { |
810 notification_search.css('background-image', currentPicto.replace('/big/' + (this.config.mouseInteractions ? 'MI/' : '') + 'valid/', '/big/' + (this.config.mouseInteractions ? 'MI/' : '') + 'hover/')); |
810 notification_search.css('background-image', currentPicto.replace('/big/' + (this.config.mouseInteractions ? 'MI/' : '') + 'valid/', '/big/' + (this.config.mouseInteractions ? 'MI/' : '') + 'hover/')); |
811 |
811 |
812 //On émet la requete de suppression de la notification. |
812 //On émet la requete de suppression de la notification. |
813 this.gestureDelRequested = true; |
813 this.gestureDelRequested = true; |
969 { |
969 { |
970 return; |
970 return; |
971 } |
971 } |
972 |
972 |
973 //Si la souris est sur l'icone, on retourne true. |
973 //Si la souris est sur l'icone, on retourne true. |
974 if(x > helpIcon.position().left && x < +helpIcon.position().left + helpIcon.width() && y > helpIcon.position().top && y < +helpIcon.position().top + helpIcon.height() + 2 * parseInt(helpIcon.css('margin'))) |
974 if(x > helpIcon.position().left && x < +helpIcon.position().left + helpIcon.width() + 2 * parseInt(helpIcon.css('margin-left')) && y > helpIcon.position().top && y < +helpIcon.position().top + helpIcon.height() + 2 * parseInt(helpIcon.css('margin-left'))) |
|
975 { |
|
976 return true; |
|
977 } |
|
978 |
|
979 return false; |
|
980 } |
|
981 |
|
982 /* |
|
983 * Retourne vrai si le doigt est sur la notification de sortie dans le mode d'interaction tablettes. |
|
984 */ |
|
985 Mosaic.prototype.isOnExitIcon = function(x, y) |
|
986 { |
|
987 var exitIcon = $('#exitIcon'); |
|
988 //S'il n'y a pas d'icone d'aide, on quitte. |
|
989 if(exitIcon.length <= 0) |
|
990 { |
|
991 return; |
|
992 } |
|
993 |
|
994 //Si la souris est sur l'icone, on retourne true. |
|
995 if(x > exitIcon.position().left && x < +exitIcon.position().left + exitIcon.width() + 2 * parseInt(exitIcon.css('margin-left')) && y > exitIcon.position().top && y < +exitIcon.position().top + exitIcon.height() + 2 * parseInt(exitIcon.css('margin-left'))) |
|
996 { |
|
997 return true; |
|
998 } |
|
999 |
|
1000 return false; |
|
1001 } |
|
1002 |
|
1003 /* |
|
1004 * Retourne vrai si le doigt est sur la notification de retour vers la mosaïque dans le mode d'interaction tablettes. |
|
1005 */ |
|
1006 Mosaic.prototype.isOnHomeIcon = function(x, y) |
|
1007 { |
|
1008 var homeIcon = $('#homeIcon'); |
|
1009 //S'il n'y a pas d'icone d'aide, on quitte. |
|
1010 if(homeIcon.length <= 0) |
|
1011 { |
|
1012 return; |
|
1013 } |
|
1014 |
|
1015 //Si la souris est sur l'icone, on retourne true. |
|
1016 if(x > homeIcon.position().left && x < +homeIcon.position().left + homeIcon.width() + 2 * parseInt(homeIcon.css('margin-left')) && y > homeIcon.position().top && y < +homeIcon.position().top + homeIcon.height() + 2 * parseInt(homeIcon.css('margin-left'))) |
|
1017 { |
|
1018 return true; |
|
1019 } |
|
1020 |
|
1021 return false; |
|
1022 } |
|
1023 |
|
1024 /* |
|
1025 * Retourne vrai si le doigt est sur la notification de sortie de recherche dans le mode d'interaction tablettes. |
|
1026 */ |
|
1027 Mosaic.prototype.isOnSearchExitIcon = function(x, y) |
|
1028 { |
|
1029 var searchExitIcon = $('#searchExitIcon'); |
|
1030 //S'il n'y a pas d'icone d'aide, on quitte. |
|
1031 if(searchExitIcon.length <= 0) |
|
1032 { |
|
1033 return; |
|
1034 } |
|
1035 |
|
1036 //Si la souris est sur l'icone, on retourne true. |
|
1037 if(x > searchExitIcon.position().left && x < +searchExitIcon.position().left + searchExitIcon.width() + 2 * parseInt(searchExitIcon.css('margin-left')) && y > searchExitIcon.position().top && y < +searchExitIcon.position().top + searchExitIcon.height() + 2 * parseInt(searchExitIcon.css('margin-left'))) |
|
1038 { |
|
1039 return true; |
|
1040 } |
|
1041 |
|
1042 return false; |
|
1043 } |
|
1044 |
|
1045 /* |
|
1046 * Retourne vrai si le doigt est sur la notification de recherche dans le mode d'interaction tablettes. |
|
1047 */ |
|
1048 Mosaic.prototype.isOnSearchNotification = function(x, y) |
|
1049 { |
|
1050 var searchNotification = $('#notify_search_1gesture'); |
|
1051 //S'il n'y a pas d'icone d'aide, on quitte. |
|
1052 if(searchNotification.length <= 0) |
|
1053 { |
|
1054 return; |
|
1055 } |
|
1056 |
|
1057 //Si la souris est sur l'icone, on retourne true. |
|
1058 if(x > searchNotification.position().left && x < +searchNotification.position().left + searchNotification.width() + 2 * parseInt(searchNotification.css('margin-left')) && y > searchNotification.position().top && y < +searchNotification.position().top + searchNotification.height() + 2 * parseInt(searchNotification.css('margin-left'))) |
975 { |
1059 { |
976 return true; |
1060 return true; |
977 } |
1061 } |
978 |
1062 |
979 return false; |
1063 return false; |