Commit 453122b9699e8003ce4388ffeb5481f70e59d38e
1 parent
521228f3
#6740:Dissectible Anatomy > Both the highlighted functions can't be active at the same time
#7424:Highlight button should not be active when user clicks on Extract button #7428:Only Highlight should be active #7429:Incorrect state of the button
Showing
2 changed files
with
133 additions
and
15 deletions
400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
... | ... | @@ -281,7 +281,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
281 | 281 | var view_list = angular.element($event.currentTarget); |
282 | 282 | var view_list_male_female = view_list.attr('title'); |
283 | 283 | |
284 | - $rootScope.Normal = "LeftButtonsDefaultState"; | |
284 | + //$rootScope.Normal = "LeftButtonsDefaultState"; | |
285 | 285 | |
286 | 286 | if (view_list_male_female == "Male") { |
287 | 287 | |
... | ... | @@ -294,6 +294,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
294 | 294 | $rootScope.female = "active"; |
295 | 295 | } |
296 | 296 | |
297 | + | |
297 | 298 | } |
298 | 299 | |
299 | 300 | |
... | ... | @@ -2461,8 +2462,28 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
2461 | 2462 | if ($rootScope.isHighLight) { |
2462 | 2463 | //alert('isHighlight: ' + $scope.isHighLight); |
2463 | 2464 | |
2464 | - $('#btnHighLight').removeClass('btn btn-black'); | |
2465 | - $('#btnHighLight').addClass('btn-primary'); | |
2465 | + //$('#btnHighLight').removeClass('btn btn-black'); | |
2466 | + //$('#btnHighLight').addClass('btn-primary'); | |
2467 | + | |
2468 | + $("#btnHighLight").addClass("btn-primary"); | |
2469 | + $("#btnHighLight").removeClass("btn-black"); | |
2470 | + | |
2471 | + if (!$("#btnNormalMode").hasClass("btn-black")) { | |
2472 | + $("#btnNormalMode").addClass("btn-black"); | |
2473 | + } | |
2474 | + | |
2475 | + if (!$("#btnExtract").hasClass("btn-black")) { | |
2476 | + $("#btnExtract").addClass("btn-black"); | |
2477 | + } | |
2478 | + | |
2479 | + if ($("#btnExtract").hasClass("btn-primary")) { | |
2480 | + $("#btnExtract").removeClass("btn-primary"); | |
2481 | + } | |
2482 | + | |
2483 | + | |
2484 | + if ($("#btnNormalMode").hasClass("btn-primary")) { | |
2485 | + $("#btnNormalMode").removeClass("btn-primary"); | |
2486 | + } | |
2466 | 2487 | |
2467 | 2488 | console.log('highLightBody call from DisableProgressBar') |
2468 | 2489 | // $scope.highLightBody(); |
... | ... | @@ -4682,9 +4703,28 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
4682 | 4703 | |
4683 | 4704 | // unhighlight other |
4684 | 4705 | |
4685 | - $scope.Normal = ""; | |
4686 | - $scope.Extract = ""; | |
4687 | - $scope.Highlight = "LeftButtonsDefaultState"; | |
4706 | + //$scope.Normal = ""; | |
4707 | + //$scope.Extract = ""; | |
4708 | + //$scope.Highlight = "LeftButtonsDefaultState"; | |
4709 | + | |
4710 | + $("#btnHighLight").addClass("btn-primary"); | |
4711 | + $("#btnHighLight").removeClass("btn-black"); | |
4712 | + | |
4713 | + if (!$("#btnNormalMode").hasClass("btn-black")) { | |
4714 | + $("#btnNormalMode").addClass("btn-black"); | |
4715 | + } | |
4716 | + | |
4717 | + if (!$("#btnExtract").hasClass("btn-black")) { | |
4718 | + $("#btnExtract").addClass("btn-black"); | |
4719 | + } | |
4720 | + | |
4721 | + if ($("#btnExtract").hasClass("btn-primary")) { | |
4722 | + $("#btnExtract").removeClass("btn-primary"); | |
4723 | + } | |
4724 | + | |
4725 | + if ($("#btnNormalMode").hasClass("btn-primary")) { | |
4726 | + $("#btnNormalMode").removeClass("btn-primary"); | |
4727 | + } | |
4688 | 4728 | } |
4689 | 4729 | |
4690 | 4730 | $scope.enableNormalMode = function () { |
... | ... | @@ -4715,9 +4755,27 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
4715 | 4755 | |
4716 | 4756 | } |
4717 | 4757 | |
4718 | - $scope.Normal = "LeftButtonsDefaultState"; | |
4719 | - $scope.Extract = ""; | |
4720 | - $scope.Highlight = ""; | |
4758 | + //$scope.Normal = "LeftButtonsDefaultState"; | |
4759 | + //$scope.Extract = ""; | |
4760 | + //$scope.Highlight = ""; | |
4761 | + $("#btnNormalMode").addClass("btn-primary"); | |
4762 | + $("#btnNormalMode").removeClass("btn-black"); | |
4763 | + | |
4764 | + if (!$("#btnExtract").hasClass("btn-black")) { | |
4765 | + $("#btnExtract").addClass("btn-black"); | |
4766 | + } | |
4767 | + | |
4768 | + if (!$("#btnHighLight").hasClass("btn-black")) { | |
4769 | + $("#btnHighLight").addClass("btn-black"); | |
4770 | + } | |
4771 | + | |
4772 | + if ($("#btnExtract").hasClass("btn-primary")) { | |
4773 | + $("#btnExtract").removeClass("btn-primary"); | |
4774 | + } | |
4775 | + | |
4776 | + if ($("#btnHighLight").hasClass("btn-primary")) { | |
4777 | + $("#btnHighLight").removeClass("btn-primary"); | |
4778 | + } | |
4721 | 4779 | } |
4722 | 4780 | |
4723 | 4781 | $scope.enableExtract = function () { |
... | ... | @@ -4755,9 +4813,28 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
4755 | 4813 | } |
4756 | 4814 | |
4757 | 4815 | //5. unhighlight other |
4758 | - $scope.Normal = ""; | |
4759 | - $scope.Extract = "LeftButtonsDefaultState"; | |
4760 | - $scope.Highlight = ""; | |
4816 | + //$scope.Normal = ""; | |
4817 | + //$scope.Extract = "LeftButtonsDefaultState"; | |
4818 | + //$scope.Highlight = ""; | |
4819 | + | |
4820 | + $("#btnExtract").addClass("btn-primary"); | |
4821 | + $("#btnExtract").removeClass("btn-black"); | |
4822 | + | |
4823 | + if (!$("#btnNormalMode").hasClass("btn-black")) { | |
4824 | + $("#btnNormalMode").addClass("btn-black"); | |
4825 | + } | |
4826 | + | |
4827 | + if (!$("#btnHighLight").hasClass("btn-black")) { | |
4828 | + $("#btnHighLight").addClass("btn-black"); | |
4829 | + } | |
4830 | + | |
4831 | + if ($("#btnNormalMode").hasClass("btn-primary")) { | |
4832 | + $("#btnNormalMode").removeClass("btn-primary"); | |
4833 | + } | |
4834 | + | |
4835 | + if ($("#btnHighLight").hasClass("btn-primary")) { | |
4836 | + $("#btnHighLight").removeClass("btn-primary"); | |
4837 | + } | |
4761 | 4838 | } |
4762 | 4839 | |
4763 | 4840 | $scope.enableShowHideStructureBox = function () { |
... | ... | @@ -6673,6 +6750,26 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
6673 | 6750 | $scope.Urinary = "active"; |
6674 | 6751 | } |
6675 | 6752 | |
6753 | + //Highlight button should be active | |
6754 | + $("#btnHighLight").addClass("btn-primary"); | |
6755 | + $("#btnHighLight").removeClass("btn-black"); | |
6756 | + | |
6757 | + if (!$("#btnNormalMode").hasClass("btn-black")) { | |
6758 | + $("#btnNormalMode").addClass("btn-black"); | |
6759 | + } | |
6760 | + | |
6761 | + if (!$("#btnExtract").hasClass("btn-black")) { | |
6762 | + $("#btnExtract").addClass("btn-black"); | |
6763 | + } | |
6764 | + | |
6765 | + if ($("#btnExtract").hasClass("btn-primary")) { | |
6766 | + $("#btnExtract").removeClass("btn-primary"); | |
6767 | + } | |
6768 | + | |
6769 | + if ($("#btnNormalMode").hasClass("btn-primary")) { | |
6770 | + $("#btnNormalMode").removeClass("btn-primary"); | |
6771 | + } | |
6772 | + | |
6676 | 6773 | } |
6677 | 6774 | |
6678 | 6775 | $scope.ShowSearch = function () { |
... | ... | @@ -6709,6 +6806,27 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
6709 | 6806 | |
6710 | 6807 | $scope.IsSearchVisible = false; |
6711 | 6808 | |
6809 | + //Highlight only Highlight button | |
6810 | + | |
6811 | + $("#btnHighLight").addClass("btn-primary"); | |
6812 | + $("#btnHighLight").removeClass("btn-black"); | |
6813 | + | |
6814 | + if (!$("#btnNormalMode").hasClass("btn-black")) { | |
6815 | + $("#btnNormalMode").addClass("btn-black"); | |
6816 | + } | |
6817 | + | |
6818 | + if (!$("#btnExtract").hasClass("btn-black")) { | |
6819 | + $("#btnExtract").addClass("btn-black"); | |
6820 | + } | |
6821 | + | |
6822 | + if ($("#btnExtract").hasClass("btn-primary")) { | |
6823 | + $("#btnExtract").removeClass("btn-primary"); | |
6824 | + } | |
6825 | + | |
6826 | + if ($("#btnNormalMode").hasClass("btn-primary")) { | |
6827 | + $("#btnNormalMode").removeClass("btn-primary"); | |
6828 | + } | |
6829 | + | |
6712 | 6830 | } |
6713 | 6831 | |
6714 | 6832 | //Function to set the vertical and horizontal scroll position of CanvasDiv as per the Navigator | ... | ... |
400-SOURCECODE/AIAHTML5.Web/app/views/da/da-view.html
... | ... | @@ -145,13 +145,13 @@ |
145 | 145 | <button id="btnTranparency" class="btn btn-black btn-sm btn-block marginTop5 tooltip-custom" ng-click="createTransparencyBox()" data-toggle="tooltip" data-placement="bottom" title="Transparency Box"><img src="content/images/icon-transparency.png" alt="" title=""></button> |
146 | 146 | </div> |
147 | 147 | <div class="col-sm-6"> |
148 | - <button ng-class="Normal" class="btn btn-black btn-sm marginTop5 tooltip-custom" ng-click="enableNormalMode()" data-toggle=" tooltip" data-placement="bottom" title="Normal"> <img src="content/images/bulb1.png" alt="" title=""></button> | |
148 | + <button id="btnNormalMode" class="btn btn-primary btn-sm marginTop5 tooltip-custom" ng-click="enableNormalMode()" data-toggle="tooltip" data-placement="bottom" title="Normal"> <img src="content/images/bulb1.png" alt="" title=""></button> | |
149 | 149 | </div> |
150 | 150 | <div class="col-sm-6"> |
151 | - <button ng-class="Extract" class="btn btn-black btn-sm pull-right marginTop5 tooltip-custom" ng-click="enableExtract()" data-toggle="tooltip" data-placement="bottom" title="Extract"><img src="content/images/bulb1.png" alt="" title=""></button> | |
151 | + <button id="btnExtract" class="btn btn-black btn-sm pull-right marginTop5 tooltip-custom" ng-click="enableExtract()" data-toggle="tooltip" data-placement="bottom" title="Extract"><img src="content/images/bulb1.png" alt="" title=""></button> | |
152 | 152 | </div> |
153 | 153 | <div class="col-sm-6"> |
154 | - <button ng-class="Highlight" id="btnHighLight" class="btn btn-black btn-sm marginTop5 tooltip-custom btn-resize" ng-click="enableHighlight()" data-toggle="tooltip" data-placement="bottom" title="Highlight"> <img src="content/images/bulb.png" alt="" title=""></button> | |
154 | + <button id="btnHighLight" class="btn btn-black btn-sm marginTop5 tooltip-custom btn-resize" ng-click="enableHighlight()" data-toggle="tooltip" data-placement="bottom" title="Highlight"> <img src="content/images/bulb.png" alt="" title=""></button> | |
155 | 155 | </div> |
156 | 156 | <div class="col-sm-6 dropdown hover-tool"> |
157 | 157 | <div class="custom-tooltip">Highlight Options</div> | ... | ... |