diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js index 289babf..65ddd82 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js @@ -11,7 +11,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $scope.imagePath = ""; $rootScope.BodyRegionData; $rootScope.BodyRegionCordinatesData; - $scope.isTransparencyActivated = false; + $rootScope.isTransparencyActivated = false; $rootScope.BodyLayerData; $rootScope.VocabTermData; @@ -1000,6 +1000,15 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $('#draggable').css('width', dragdivw); $('#draggable').css('height', dragdivh) + + document.getElementById('btnTranparency').addEventListener('click', $scope.createTransparencyBox); + document.getElementById('btnNormalMode').addEventListener('click', $scope.enableNormalMode); + document.getElementById('btnExtract').addEventListener('click', $scope.enableExtract); + document.getElementById('btnHighLight').addEventListener('click', $scope.enableHighlight); + document.getElementById('btnIdentity').addEventListener('click', $scope.OnIdentityClick); + document.getElementById('btnZoom').addEventListener('click', $scope.enableZoom); + document.getElementById('btnTBoxClose').addEventListener('click', $scope.CloseTransparencyBox); + } function scaleRectangle(x, y, height, width, mirrorValue) { @@ -2430,7 +2439,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo //layer change function $scope.LayerChange = function () { - + //if listanager is visisble then close it // $rootScope.isListManagerSelected = false; @@ -2455,7 +2464,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo if ($scope.isTransparencyActivated) { - + debugger; //crete temp canavs to store the original data which will be used to chnange the transparency if (document.getElementById('tempCanvas') != null) { $('#tempCanvas').remove(); @@ -3435,7 +3444,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $scope.createTransparencyBox = function () { - $scope.isTransparencyActivated = true; + $rootScope.isTransparencyActivated = true; //do not create TBOX if in extarct mode otherwise create if ($rootScope.isExtract == false) { @@ -4564,8 +4573,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $scope.CloseTransparencyBox = function () { + alert('CloseTransparencyBox is called'); //To enable extract button - $scope.isTransparencyActivated = false; + $rootScope.isTransparencyActivated = false; $("#btnExtract").removeClass("disabled"); $('.com_anno').css('display', 'none'); @@ -4602,7 +4612,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo //var scope = angular.element(document.getElementById("DAView")).scope(); //scope.$apply(function () { // $scope.layerNumber = 0; - $scope.isTransparencyActivated = false; + // $rootScope.isTransparencyActivated = false; //}) @@ -4621,7 +4631,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo } $('#transparencyScale').css('visibility', 'hidden'); - $scope.isTransparencyActivated = false; + //$rootScope.isTransparencyActivated = false; // document.getElementById('btnTranparency').className = 't-transparency' $('#btnTranparency').removeClass('tButtonActive'); $('#btnTranparency').addClass('btn-black'); @@ -4685,9 +4695,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo $rootScope.CloseListManager(); // $('#btnIdentity').addClass('btn-primary'); - if ($scope.isTransparencyActivated == true) { + if ($rootScope.isTransparencyActivated == true) { - $scope.isTransparencyActivated = false; + $rootScope.isTransparencyActivated = false; var canvasDiv = document.getElementById('canvasDiv'); canvasDiv.removeEventListener("mousedown", mouseDownListener); @@ -5042,7 +5052,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo - if ($scope.isTransparencyActivated == true) { + if ($rootScope.isTransparencyActivated == true) { $("#btnExtract").addClass("disabled"); @@ -5590,7 +5600,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo } - $scope.OnGenderChange = function (event) { + $scope.OnGenderChange = function (gender) { @@ -7874,4 +7884,86 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo } }] -); \ No newline at end of file +); + + +function OnGenderChange(gender) { + + console.log('gender chnaged is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.OnGenderChange(gender); + }); +} + +function OnViewChange(bodyView) { + console.log('OnViewChange chnaged is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.OnViewChange(bodyView); + }); +} + +function OnBodySystem(bodySytem) { + console.log('OnBodySystem chnaged is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.HighlightBodyByBodySystem(bodySytem); + }); +} + +function enableShowHideStructureBox() { + console.log('OnBodySystem chnaged is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.enableShowHideStructureBox(); + }); +} + +function OnSearch() { + console.log('Show Search is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.ShowSearch(); + }); +} +function selectTerm(event) { + console.log('selectTerm is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.jumpToTerm(event); + }); +} +function HighlightBodyOnListManager(event) { + console.log('HighlightBodyOnListManager is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.HighlightBodyOnListManagerSelection(event); + }); +} + +function refreshTermListOnSystem(event) { + console.log('refreshTermListOnSystem is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.refreshTermListOnSystemSelection(event); + }); +} + +function OnEnableExtract() +{ + console.log('OnEnableExtract is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.enableExtract('true'); + }); +} + +function onTboxCreation() +{ + console.log('OnEnableExtract is called outside '); + var scope = angular.element(document.getElementById("daView")).scope(); + scope.$apply(function () { + scope.createTransparencyBox('true'); + }); +} diff --git a/400-SOURCECODE/AIAHTML5.Web/app/views/da/da-view.html b/400-SOURCECODE/AIAHTML5.Web/app/views/da/da-view.html index 02d7b00..1367b80 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/views/da/da-view.html +++ b/400-SOURCECODE/AIAHTML5.Web/app/views/da/da-view.html @@ -54,6 +54,7 @@ .tooltip-custom + .tooltip > .tooltip-arrow { display: none; } + .customTooltip { background: #333 !important; color: #fff !important; @@ -142,37 +143,37 @@
@@ -233,14 +261,15 @@