Commit 517d9fa84409a0f4ffc38ac6463b7b94b0b3c97a

Authored by Nikita Kulshreshtha
1 parent c982ce6d

Multi annotatino will work with command on MAC. metakey is true for command press

400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
@@ -1464,7 +1464,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l @@ -1464,7 +1464,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l
1464 $scope.isLayerChange = false; 1464 $scope.isLayerChange = false;
1465 } 1465 }
1466 1466
1467 - if (evt.ctrlKey) { 1467 + if (evt.ctrlKey || evt.metaKey) {
1468 $rootScope.multiAnnotationIsON = true; 1468 $rootScope.multiAnnotationIsON = true;
1469 1469
1470 //document.getElementById("btnZoom").setAttribute('disabled', 'disabled'); 1470 //document.getElementById("btnZoom").setAttribute('disabled', 'disabled');
@@ -1880,7 +1880,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l @@ -1880,7 +1880,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l
1880 $scope.isLayerChange = false; 1880 $scope.isLayerChange = false;
1881 } 1881 }
1882 1882
1883 - if (evt.ctrlKey) { 1883 + if (evt.ctrlKey || evt.metaKey) {
1884 $rootScope.multiAnnotationIsON = true; 1884 $rootScope.multiAnnotationIsON = true;
1885 1885
1886 //$("#btnZoom").addClass('disabled'); 1886 //$("#btnZoom").addClass('disabled');
@@ -3615,7 +3615,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l @@ -3615,7 +3615,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l
3615 // we decide the size of speech bubble 3615 // we decide the size of speech bubble
3616 //2. 3616 //2.
3617 3617
3618 - if (event.ctrlKey) { 3618 + if (event.ctrlKey || event.metaKey) {
3619 console.log('ctrl pressed'); 3619 console.log('ctrl pressed');
3620 $scope.multiAnnotationIsON = true; 3620 $scope.multiAnnotationIsON = true;
3621 //2.1 create unique speech bubbles 3621 //2.1 create unique speech bubbles
@@ -3684,7 +3684,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l @@ -3684,7 +3684,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l
3684 else { 3684 else {
3685 $scope.longest_annotationT1 = $scope.annotationTextArrayT1.reduce(function (a, b) { return a.length > b.length ? a : b; }); 3685 $scope.longest_annotationT1 = $scope.annotationTextArrayT1.reduce(function (a, b) { return a.length > b.length ? a : b; });
3686 $scope.longest_annotationT2 = $scope.annotationTextArrayT2.reduce(function (a, b) { return a.length > b.length ? a : b; }); 3686 $scope.longest_annotationT2 = $scope.annotationTextArrayT2.reduce(function (a, b) { return a.length > b.length ? a : b; });
3687 - if (event.ctrlKey) { 3687 + if (event.ctrlKey || event.metaKey) {
3688 $scope.j = $scope.j + 1; 3688 $scope.j = $scope.j + 1;
3689 var sub_id_annotation = "black_annotation" + $scope.j; 3689 var sub_id_annotation = "black_annotation" + $scope.j;
3690 var pointClicked_annotation = parseInt(x) + parseInt(y); 3690 var pointClicked_annotation = parseInt(x) + parseInt(y);