Commit ca97b013037b6fc757c487ec21b7d60ce334a457

Authored by Amrita Vishnoi
2 parents 5f257280 453122b9

Refs: #6740

Dissectible Anatomy > Both the highlighted functions can't be active at the same time
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  
... ... @@ -2464,6 +2465,26 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
2464 2465 //$('#btnHighLight').removeClass('btn btn-black');
2465 2466 //$('#btnHighLight').addClass('btn-primary');
2466 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 + }
  2487 +
2467 2488 console.log('highLightBody call from DisableProgressBar')
2468 2489 // $scope.highLightBody();
2469 2490  
... ... @@ -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 () {
... ... @@ -6677,6 +6754,26 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
6677 6754 $scope.Urinary = "active";
6678 6755 }
6679 6756  
  6757 + //Highlight button should be active
  6758 + $("#btnHighLight").addClass("btn-primary");
  6759 + $("#btnHighLight").removeClass("btn-black");
  6760 +
  6761 + if (!$("#btnNormalMode").hasClass("btn-black")) {
  6762 + $("#btnNormalMode").addClass("btn-black");
  6763 + }
  6764 +
  6765 + if (!$("#btnExtract").hasClass("btn-black")) {
  6766 + $("#btnExtract").addClass("btn-black");
  6767 + }
  6768 +
  6769 + if ($("#btnExtract").hasClass("btn-primary")) {
  6770 + $("#btnExtract").removeClass("btn-primary");
  6771 + }
  6772 +
  6773 + if ($("#btnNormalMode").hasClass("btn-primary")) {
  6774 + $("#btnNormalMode").removeClass("btn-primary");
  6775 + }
  6776 +
6680 6777 }
6681 6778  
6682 6779 $scope.ShowSearch = function () {
... ... @@ -6713,6 +6810,27 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
6713 6810  
6714 6811 $scope.IsSearchVisible = false;
6715 6812  
  6813 + //Highlight only Highlight button
  6814 +
  6815 + $("#btnHighLight").addClass("btn-primary");
  6816 + $("#btnHighLight").removeClass("btn-black");
  6817 +
  6818 + if (!$("#btnNormalMode").hasClass("btn-black")) {
  6819 + $("#btnNormalMode").addClass("btn-black");
  6820 + }
  6821 +
  6822 + if (!$("#btnExtract").hasClass("btn-black")) {
  6823 + $("#btnExtract").addClass("btn-black");
  6824 + }
  6825 +
  6826 + if ($("#btnExtract").hasClass("btn-primary")) {
  6827 + $("#btnExtract").removeClass("btn-primary");
  6828 + }
  6829 +
  6830 + if ($("#btnNormalMode").hasClass("btn-primary")) {
  6831 + $("#btnNormalMode").removeClass("btn-primary");
  6832 + }
  6833 +
6716 6834 }
6717 6835  
6718 6836 //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
... ... @@ -148,14 +148,14 @@
148 148  
149 149  
150 150 <div class="col-sm-6">
151   - <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=""></button>
  151 + <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>
152 152 </div>
153 153 <div class="col-sm-6">
154   - <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=""></button>
  154 + <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>
155 155 </div>
156 156  
157 157 <div class="col-sm-6">
158   - <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=""></button>
  158 + <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>
159 159 </div>
160 160  
161 161 <div class="col-sm-6 dropdown hover-tool">
... ...