diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
index 544ce6a..447bf5d 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
@@ -1459,10 +1459,6 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
{
if ($rootScope.isHighLight == true || ($rootScope.isListManagerSelected == true) || (($rootScope.isGenderChnage == true) && ($rootScope.isHighLight == true)) || (($rootScope.isViewChange == true) && ($rootScope.isHighLight == true))) {
- $rootScope.isLoading = false;
- $('#spinner').css('visibility', 'hidden');
-
-
$rootScope.isLoading = true;
$('#spinner').css('visibility', 'visible');
//$timeout(function () {
@@ -1785,13 +1781,10 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
if ($rootScope.isHighLight == true || ($rootScope.isListManagerSelected == true) || (($rootScope.isGenderChnage == true) && ($rootScope.isHighLight == true)) || (($rootScope.isViewChange == true) && ($rootScope.isHighLight == true))) {
- $rootScope.isLoading = false;
- $('#spinner').css('visibility', 'hidden');
-
$rootScope.isLoading = true;
$('#spinner').css('visibility', 'visible');
- //$timeout(function () {
+
console.log('inside start of non flipped. $scope.ColoredImageSRC.length= ' + $scope.ColoredImageSRC.length)
$rootScope.isHighLight = true;
@@ -1800,7 +1793,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.highLightBody();
console.log('just after highLightBody call');
- //}, 500);
+
}
}
}
@@ -2059,6 +2052,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
// $rootScope.updatedGrayDataList = null;
// $rootScope.updatedGrayDataList = [];
//}
+ $rootScope.isLoading = true;
+ $('#spinner').css('visibility', 'visible');
+
if ($rootScope.isHighLight == true) {
false;
@@ -5033,6 +5029,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.highLightBody = function () {
+ $rootScope.isLoading = true;
+ $('#spinner').css('visibility', 'visible');
+
$scope.Normal = "";
$scope.Extract = "";
$scope.Highlight = "LeftButtonsDefaultState";
@@ -5216,6 +5215,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
// console.log('$scope.grayedBR.length is ' + $scope.grayedBR.length);
$timeout(function () {
+ $scope.isLoading = true;
+ $('#spinner').css('visibility', 'visible');
+
$scope.HighlightBodyByTermList($scope.AllTerms)
}, 800);
@@ -7170,7 +7172,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.jumpToTerm = function (event) {
-
+ $rootScope.isLoading = true;
+
+ $('#spinner').css('visibility', 'visible');
//1.
$scope.searchFilter = event.currentTarget.innerHTML;
@@ -7248,7 +7252,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
-
+ $('#viewName').empty();
var currentView = localStorage.getItem("currentViewTitle");
var viewNmeHtml = ''
$('#viewName').append(viewNmeHtml);
@@ -7318,6 +7322,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
for (var j = 0; j < $scope.VocabTermTxt.length; j++) {
var $el = $('').appendTo('#termList')
$compile($el)($scope);
+
$rootScope.isLoading = false;
$('#spinner').css('visibility', 'hidden');
}
@@ -7512,6 +7517,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
}
}
+
$scope.aligneCanvasWithTerm = function () {
console.log('aligneCanvasWithTerm')
var newX = parseInt($scope.scaleValue($scope.termCoordinate.x, $scope.zoomInOut, DA[0].ZOOM_TERM_DATA));
@@ -7519,30 +7525,45 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
var canvasX = parseInt($('#canvasDiv').css('left'));
var canvasY = parseInt($('#canvasDiv').css('top'));
- var canvasWidth = parseInt($('#canvasDiv').css('width'));
- var canvasHeight = parseInt($('#canvasDiv').css('height'));
+ var canvasHeight = $('#canvasDiv').height();
+ var canvasWidth = $('#canvasDiv').width();
+
var canvasBottom = canvasY + canvasHeight;
var canvasRight = canvasX + canvasWidth
-
- if (newX >= canvasX && newX <= canvasRight && newY >= canvasY && newY <= canvasBottom) {
-
- }
- else {
+ if (newX < canvasX || newX > canvasRight || newY < canvasY || newY > canvasBottom) {
+
newX = newX - canvasWidth / 2;
newY = newY - canvasHeight / 2;
- }
+ var maxVScrollPos = $('#canvasDiv')[0].scrollHeight;
+ var maxHScrollPos = $('#canvasDiv')[0].scrollWidth;
+ if (newY < maxVScrollPos) {
+ newY = newY;
+ }
+ else {
+ newY = maxVScrollPos;
+ }
+
+ if (newX < maxHScrollPos) {
+ newX = newX;
+ }
+ else {
+ newX = maxHScrollPos;
+ }
+ $('#canvasDiv').scrollLeft(newX);
+ $('#canvasDiv').scrollTop(newY);
- console.log('newX =' + newX + ',newY= ' + newY)
- $rootScope.xOnSearch= $('#canvasDiv').scrollLeft(newX);
- $rootScope.yOnSearch = $('#canvasDiv').scrollTop(newY);
+ }
+ $scope.isLoading = false;
+ $('#spinner').css('visibility', 'hidden');
}
+
$scope.scaleValue = function (nValue, nNewZoom, nExistingZoom) {
var iReturnValue = nValue * nNewZoom;
diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
index 1c3529f..8d33437 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
@@ -441,6 +441,10 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location",
//$rootScope.isListManagerSelected = false;
$('#listManager').css('display', 'none');
$("#listManager").css("visibility", "hidden");
+
+ $rootScope.isLoading = false;
+ $('#spinner').css('visibility', 'hidden');
+ //$('#spinner').css('display', 'none');
// $rootScope.isAnnotationWindowClose = true;
// if('#termList')
if ($('#termList option').length > 0) {