From 3b4ca7465fd89bd74c4f644ce846261237f75427 Mon Sep 17 00:00:00 2001 From: nikita Date: Thu, 9 Feb 2017 14:09:51 +0530 Subject: [PATCH] disabled/remove transparency when there is highlight of any part in any case --- 400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js | 15 +++++++++++---- 400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js | 3 ++- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js index 72a1840..fc3f72d 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js @@ -2346,6 +2346,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $scope.HighlightBodyByTermList = function (TermList) { + $("#btnTranparency").attr('disabled', 'disabled'); + $scope.currentLayerNumber = $scope.layerNumber; + $scope.layerNumber = $('#txtlayerNumber').val(); $rootScope.isLoading = true; @@ -3933,7 +3936,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo document.getElementById('canvasDiv').removeEventListener("mousedown", mouseDownListener); //Dated:19-07-2016 Issue#4975: Transparency box should not be clickable if it is already selected. - if ($("#txtlayerNumber").val() != 0) { + if ($("#txtlayerNumber").val() != 0 && $scope.currentLayerNumber != undefined) { $('#layerChangeSlider').slider("option", "value", parseInt($rootScope.totalLayers) - parseInt($scope.currentLayerNumber)); $("#txtlayerNumber").val(parseInt($scope.currentLayerNumber)); } @@ -5935,7 +5938,8 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo // $("#btnExtract").removeClass("disabled"); - $("#btnTranparency").removeClass("disabled"); + // $("#btnTranparency").removeClass("disabled"); + $("#btnTranparency").removeAttr('disabled', 'disabled'); // $rootScope.isTransparencyBoxActivated = false; // $rootScope.isNormalMode = false; @@ -6006,7 +6010,8 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo } $scope.enableNormalMode = function () { - $("#btnTranparency").removeClass("disabled"); + // $("#btnTranparency").removeClass("disabled"); + $("#btnTranparency").removeAttr('disabled', 'disabled'); $rootScope.isNormalMode = false; console.log('enableNormalMode is called'); @@ -6236,7 +6241,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $scope.highLightBody = function () { - + $scope.CloseTransparencyBox(); $scope.Normal = ""; $scope.Extract = ""; $scope.Highlight = "LeftButtonsDefaultState"; @@ -7751,6 +7756,8 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $scope.HighlightBodyOnListManagerSelection = function (actualTermNumber) { + $scope.CloseTransparencyBox(); + console.log('inside HighlightBodyOnListManagerSelection actualTermNumber= ' + actualTermNumber) // Terms search in the Search list should be disable in the List Manager and Vice-Versa. if ($rootScope.prevId == actualTermNumber) { diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js index 0f5de1d..61c8609 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js @@ -2297,7 +2297,8 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic $rootScope.CloseListManager = function () { - + +$("#btnTranparency").removeAttr('disabled', 'disabled'); + console.log('close'); $rootScope.disableAnnotationtoolOnListManager = false; if ($rootScope.MenuModuleName == "DA") { -- libgit2 0.21.4