diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js index 4b345b6..0329ce9 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js @@ -687,9 +687,8 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l //da-body-views functions $scope.openBodyView = function (damoduledata) { - document.getElementById('index').style.pointerEvents = "none"; + document.getElementById('index').style.pointerEvents = "none"; document.getElementById('index').style.opacity = "0.7"; - $scope.daOpenInOtherModules = damoduledata; var windowviewid = $rootScope.MULTI_VIEW_ID; @@ -1955,7 +1954,8 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l $('#transparencyScale_' + windowviewid).css('visibility', 'visible'); } else { - canDiv.innerHTML = ''; + // canDiv.innerHTML = '';COMMENTED TO MAINTAIN ANNOTATION TOOLBAR HISTORY ON HIGHLIGHT TO NORMAL MODE(Bug #22561) + $scope.flushCanvas(windowviewid); //remove transparency scale $('#transparencyScale_' + windowviewid).css('visibility', 'hidden'); } @@ -3678,19 +3678,24 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l if ($scope.GetwindowStoreData(windowviewid,'multiAnnotationIsON') == true) { //on layer change we need the fresh data not the updated one if ($scope.isLayerChange == true) { - if (grayImageMRDataList[bodyRegionId] != null || grayImageMRDataList[bodyRegionId] != undefined) { + if ($rootScope.isAnnotatiomToolBarPopupActive == true && (updatedGrayDataList[bodyRegionId - 1] != null || updatedGrayDataList[bodyRegionId - 1] != undefined)) { + + grayImageDataVar = updatedGrayDataList[bodyRegionId - 1]; + } + + else if (grayImageMRDataList[bodyRegionId] != null || grayImageMRDataList[bodyRegionId] != undefined) { grayImageDataVar = grayImageMRDataList[bodyRegionId]; } } else { if (updatedGrayDataList[bodyRegionId - 1] == null || updatedGrayDataList[bodyRegionId - 1] == undefined) { - if (grayImageMRDataList[bodyRegionId] != null || grayImageMRDataList[bodyRegionId] != undefined) { + if (grayImageMRDataList[bodyRegionId] != null || grayImageMRDataList[bodyRegionId] != undefined) { grayImageDataVar = grayImageMRDataList[bodyRegionId]; } } else { - if (updatedGrayMRDataList[bodyRegionId] != null || updatedGrayMRDataList[bodyRegionId] != undefined) { + if (updatedGrayMRDataList[bodyRegionId] != null || updatedGrayMRDataList[bodyRegionId] != undefined) { grayImageDataVar = updatedGrayMRDataList[bodyRegionId] } } @@ -3710,23 +3715,28 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l //on layer change we need the fresh data not the updated one if ($scope.isLayerChange == true) { - if (grayImageDataList[bodyRegionId - 1] != null || grayImageDataList[bodyRegionId - 1] != undefined) { - grayImageDataVar = grayImageDataList[bodyRegionId - 1]; + if ($rootScope.isAnnotatiomToolBarPopupActive == true && (updatedGrayDataList[bodyRegionId - 1] != null || updatedGrayDataList[bodyRegionId - 1] != undefined)) { + + grayImageDataVar = updatedGrayDataList[bodyRegionId - 1]; + } + + else if (grayImageDataList[bodyRegionId - 1] != null || grayImageDataList[bodyRegionId - 1] != undefined) { + grayImageDataVar = grayImageDataList[bodyRegionId - 1]; } } else { // this code is for the case where user first click on normal mode then extract then again highlight then we need to call highlight body in gray mode //and then highlight the previously selected body regions at the time of normal mode. - if (updatedGrayDataList[bodyRegionId - 1] == null || updatedGrayDataList[bodyRegionId - 1] == undefined) { - - if (grayImageDataList[bodyRegionId - 1] != null || grayImageDataList[bodyRegionId - 1] != undefined) { + if (updatedGrayDataList[bodyRegionId - 1] == null || updatedGrayDataList[bodyRegionId - 1] == undefined) + { + if (grayImageDataList[bodyRegionId - 1] != null || grayImageDataList[bodyRegionId - 1] != undefined) { grayImageDataVar = grayImageDataList[bodyRegionId - 1]; } } else { - if (updatedGrayDataList[bodyRegionId - 1] != null || updatedGrayDataList[bodyRegionId - 1] != undefined) { + if (updatedGrayDataList[bodyRegionId - 1] != null || updatedGrayDataList[bodyRegionId - 1] != undefined) { // for normal case means without interdepency button case. grayImageDataVar = updatedGrayDataList[bodyRegionId - 1]; } @@ -6519,7 +6529,9 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l // History Maintained Issue// $rootScope.getAnnotationTextBasedOnSelectedBodyRegion = function (event) { - + if (event.ctrlKey) { + $scope.SetwindowStoreData(windowviewid, 'multiAnnotationIsON') + } var len= (event.currentTarget.id).split("_").length; var windowviewid = (event.currentTarget.id).split("_")[len-1]; @@ -6599,7 +6611,13 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l if (TermAnnotationText.length>0) { $scope.createDynamicSpeechBubble(event, event.pageX + horizontlScrollPosition - $('#canvasDivDA_' + windowviewid).offset().left, event.pageY + verticalScrollPosition - $('#canvasDivDA_' + windowviewid).offset().top, true, 0, 0,windowviewid) } + var previousHighlightList = $scope.GetwindowStoreData(windowviewid, 'previousHighlightList'); + previousHighlightList.push(RGBColor); + // $scope.GetwindowStoreData(windowviewid, 'previousHighlightList', previousHighlightList); + if ($scope.GetwindowStoreData(windowviewid,'isHighLight') == true) { + $scope.highLightBodyBasedOnIcolor(RGBColor, windowviewid); + } } $rootScope.setSelectedBodyRegionData = function (windowviewid) { @@ -7777,7 +7795,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l } $scope.enableNormalMode = function (windowviewid) { - $scope.SetwindowStoreData(windowviewid,'previousHighlightList',[]); + // $scope.SetwindowStoreData(windowviewid,'previousHighlightList',[]); $('#btnTranparency_' + windowviewid).removeClass("disabled"); $('#btnTranparency_' + windowviewid).css("pointer-events", "auto");