diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js index d8d3a6e..3125616 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js @@ -724,6 +724,15 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo //calculate coordinates for body region images $scope.CalculateImageCordinates = function (viewOrientationId) { + // annotation toolbar canvas + if ($("#canvasDiv").find("canvas[id='canvasPaint']").length == 0) { + + $("#canvasDiv").append(''); + $scope.doClick(); + $rootScope.FreeStylePaint(); + + } + $scope.terminateCurrentlyRunningWPs(); var drawnBodyRegionCount = []; @@ -1421,14 +1430,6 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo context.drawImage(img, 0, 0); context.restore(); - - if ($("#canvasDiv").find("canvas[id='canvasPaint']").length == 0) { - - $("#canvasDiv").append(''); - $scope.doClick(); - $rootScope.FreeStylePaint(); - - } if (isMaskImage == 'N') { @@ -1754,14 +1755,6 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo context.drawImage(img, 0, 0); - if ($("#canvasDiv").find("canvas[id='canvasPaint']").length == 0) { - - $("#canvasDiv").append(''); - $scope.doClick(); - $rootScope.FreeStylePaint(); - - } - if (isMaskImage == 'N') { if (bodyRegionId == 'modestyImg3' || bodyRegionId == 'modestyImg2') { @@ -2559,6 +2552,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $('#canvasDiv').scrollLeft($scope.imageHorizontlScrollPosition) $('#canvasDiv').scrollTop($scope.imageVerticalScrollPosition) + if ( $rootScope.isHighlightBodyByBodySystem) { $timeout(function () { $scope.DisableProgressBar() }, 20000); } @@ -6034,6 +6028,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $rootScope.resetText = 0; $rootScope.resetTextSave = 0; $rootScope.ObjectIndexSave = 0; + var arrayRect = {}; @@ -6081,7 +6076,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo break; case "Line": - + $rootScope.resetLine = $rootScope.ObjectIndex++; $('#canvas').addLayer({ name: 'Line_' + $rootScope.resetLine, @@ -6093,7 +6088,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo rounded: true, x1: $scope.offsetX1, y1: $scope.offsetY1, x2: $scope.x, y2: $scope.y, - + click: function (layer) { $rootScope.canvasLayerNameCollection = []; $rootScope.canvasLayerNameCollection.push(layer.name); @@ -6242,7 +6237,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo click: function (layer) { - // alert(layer.name); + $rootScope.canvasLayerNameCollection = []; $rootScope.canvasLayerNameCollection.push(layer.name); $('#canvas').setLayer(layer.name, { @@ -6570,6 +6565,8 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo } + + //-- TextArea functionality of Annotation toolbar $rootScope.fontSizes; diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js index d6de654..482a4fe 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js @@ -89,15 +89,15 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", } } - $rootScope.DrawLine = function () { + // $rootScope.DrawLine = function () { //$rootScope.isIdetifyClicked = false; //$rootScope.isDrawingToolSelected = true; //$rootScope.isLineDrawSelecyed = true; - $rootScope.shapeType = "Line"; + // $rootScope.shapeType = "Line"; // alert($rootScope.shapeType); - } + // } $rootScope.ClearIframe = function () { if ($('#daImagePanel') != null) @@ -159,20 +159,26 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", //----Annotation Toolbar: Jcanvas----- - $rootScope.DrawLine = function (e) { + $rootScope.DrLine = function (e) { + + $("#canvasPaint").css("display", "block"); + $("#canvas").css("display", "block"); + $rootScope.switchCanvas(); $rootScope.shapeType = "Line"; - - + $('.btnCursor').removeClass('activebtncolor'); - $(".btn-annotation").removeClass("activebtncolor"); - $(".btn-annotation-line").addClass("activebtncolor"); - + $(".btn-annotation").removeClass("activebtncolor"); + $(".btn-annotation-line").addClass("activebtncolor"); } - $rootScope.DrawPin = function (e) { + $rootScope.DrPin = function (e) { + $("#canvasPaint").css("display", "block"); + $("#canvas").css("display", "block"); + + $rootScope.switchCanvas(); $rootScope.switchCanvas(); $rootScope.shapeType = "Pin"; @@ -191,6 +197,7 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", } $rootScope.DrawRectangle = function (e) { + $("#canvasPaint").css("display", "block"); $("#canvas").css("display", "block"); $rootScope.switchCanvas(); diff --git a/400-SOURCECODE/AIAHTML5.Web/index.html b/400-SOURCECODE/AIAHTML5.Web/index.html index b02ef0a..3531f7f 100644 --- a/400-SOURCECODE/AIAHTML5.Web/index.html +++ b/400-SOURCECODE/AIAHTML5.Web/index.html @@ -431,12 +431,12 @@
- +
- +