diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
index cf74d92..d5c89e5 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;
+ $scope.isTransparencyActivated = false;
$rootScope.BodyLayerData;
$rootScope.VocabTermData;
@@ -3422,31 +3422,41 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.createTransparencyBox = function () {
+ $scope.isTransparencyActivated = true;
- //if listanager is visisble then close it
-
- $rootScope.isListManagerSelected = false;
- $rootScope.CloseListManager();
+ //do not create TBOX if in extarct mode otherwise create
+ if ($rootScope.isExtract == false) {
+ $("#btnExtract").addClass("disabled");
- $scope.isTransparencyActivated = true;
- // alert('transparencyClicked' + $scope.isTransparencyActivated)
- $('#btnTranparency').addClass('tButtonActive');
- $('#btnIdentity').removeClass(' btn-primary');
- $('#btnIdentity').addClass('btn-black');
+ //if listanager is visisble then close it
+ $rootScope.isListManagerSelected = false;
+ $rootScope.CloseListManager();
- var canvasDiv = document.getElementById('canvasDiv');
- $scope.verticalScrollPosition = canvasDiv.scrollTop;
- $scope.horizontlScrollPosition = canvasDiv.scrollLeft;
- var canvasDiv = document.getElementById('canvasDiv');
- canvasDiv.addEventListener("mousedown", mouseDownListener);
+
+ // alert('transparencyClicked' + $scope.isTransparencyActivated)
+ $('#btnTranparency').addClass('tButtonActive');
+ $('#btnIdentity').removeClass(' btn-primary');
+ $('#btnIdentity').addClass('btn-black');
- canvasDiv.addEventListener("mousemove", mouseMoveListener);
+ var canvasDiv = document.getElementById('canvasDiv');
+ $scope.verticalScrollPosition = canvasDiv.scrollTop;
+ $scope.horizontlScrollPosition = canvasDiv.scrollLeft;
- canvasDiv.addEventListener("mouseup", mouseUpListener)
+ var canvasDiv = document.getElementById('canvasDiv');
+ canvasDiv.addEventListener("mousedown", mouseDownListener);
-
+ canvasDiv.addEventListener("mousemove", mouseMoveListener);
+
+ canvasDiv.addEventListener("mouseup", mouseUpListener)
+
+ }
+ else {
+
+ // console.log("extract button is active");
+
+ }
}
function mouseDownListener(e) {
@@ -4522,6 +4532,10 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.CloseTransparencyBox = function () {
+ //To enable extract button
+ $scope.isTransparencyActivated = false;
+ $("#btnExtract").removeClass("disabled");
+
$('.com_anno').css('display', 'none');
$('#sppeachBubble_annotation').css('display', 'none');
@@ -4957,61 +4971,77 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
//if listanager is visisble then close it
// $rootScope.isListManagerSelected = false;
- $rootScope.CloseListManager();
- //1.
- $rootScope.isLoading = true;
- $('#spinner').css('visibility', 'visible');
- //2.
- $scope.terminateCurrentlyRunningWPs();
- //3.
- if ($rootScope.isExtract == true) {
+ if ($scope.isTransparencyActivated == true) {
+
+ $("#btnExtract").addClass("disabled");
}
+
+
else {
- $rootScope.isExtract = true;
+
+ $rootScope.CloseListManager();
+ //1.
+ $rootScope.isLoading = true;
+ $('#spinner').css('visibility', 'visible');
+
+ //2.
+ $scope.terminateCurrentlyRunningWPs();
- if ($rootScope.isNormalMode == true) {
+ //3.
+ if ($rootScope.isExtract == true) {
- $rootScope.isHighLight = false;
- $rootScope.isNormalMode = false;
}
else {
- $rootScope.isNormalMode = false;
- $rootScope.isHighLight = false;
- }
+ $rootScope.isExtract = true;
+ //disable transparency button
+
+ $("#btnTranparency").addClass("disabled");
- //4.
- console.log('highLightBody from enableExtract')
- $scope.highLightBody();
+ if ($rootScope.isNormalMode == true) {
- }
+ $rootScope.isHighLight = false;
+ $rootScope.isNormalMode = false;
+ }
+ else {
+ $rootScope.isNormalMode = false;
+ $rootScope.isHighLight = false;
+ }
- //5. unhighlight other
- //$scope.Normal = "";
- //$scope.Extract = "LeftButtonsDefaultState";
- //$scope.Highlight = "";
+ //4.
+ console.log('highLightBody from enableExtract')
+ $scope.highLightBody();
- $("#btnExtract").addClass("btn-primary");
- $("#btnExtract").removeClass("btn-black");
- if (!$("#btnNormalMode").hasClass("btn-black")) {
- $("#btnNormalMode").addClass("btn-black");
- }
+ }
- if (!$("#btnHighLight").hasClass("btn-black")) {
- $("#btnHighLight").addClass("btn-black");
- }
+ //5. unhighlight other
+ //$scope.Normal = "";
+ //$scope.Extract = "LeftButtonsDefaultState";
+ //$scope.Highlight = "";
- if ($("#btnNormalMode").hasClass("btn-primary")) {
- $("#btnNormalMode").removeClass("btn-primary");
- }
+ $("#btnExtract").addClass("btn-primary");
+ $("#btnExtract").removeClass("btn-black");
- if ($("#btnHighLight").hasClass("btn-primary")) {
- $("#btnHighLight").removeClass("btn-primary");
+ if (!$("#btnNormalMode").hasClass("btn-black")) {
+ $("#btnNormalMode").addClass("btn-black");
+ }
+
+ if (!$("#btnHighLight").hasClass("btn-black")) {
+ $("#btnHighLight").addClass("btn-black");
+ }
+
+ if ($("#btnNormalMode").hasClass("btn-primary")) {
+ $("#btnNormalMode").removeClass("btn-primary");
+ }
+
+ if ($("#btnHighLight").hasClass("btn-primary")) {
+ $("#btnHighLight").removeClass("btn-primary");
+ }
}
}