diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
index 1d54aa5..28ffb84 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
@@ -97,7 +97,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.IsSearchVisible = false;
- $scope.shapesize = 1;
+
$scope.dragdivposition = {
"left": $scope.dragdivleft,
"top": $scope.dragdivtop
@@ -224,9 +224,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
userEthnicity = $rootScope.globalSetting.ethnicity;
}
- var curentmodesty = localStorage.getItem("globalModesty");
+ var curentmodesty = localStorage.getItem("globalmodesty");
if (typeof (curentmodesty) !== "undefined" && curentmodesty !== null) {
- userModestysettings = curentmodesty;
+ userModestysettings = curentmodesty
}
else {
userModestysettings = $rootScope.globalSetting.modesty;
@@ -355,7 +355,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$rootScope.globalSetting.ethnicity = curentEthnicity;
}
- var curentmodesty = localStorage.getItem("globalModesty");
+ var curentmodesty = localStorage.getItem("globalmodesty");
if (typeof (curentmodesty) !== "undefined" && curentmodesty !== null) {
$rootScope.globalSetting.modesty = curentmodesty
}
@@ -1434,11 +1434,11 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$rootScope.isLoading = true;
$('#spinner').css('visibility', 'visible');
//$timeout(function () {
- console.log('inside start of flipped. $scope.ColoredImageSRC.length= ' + $scope.ColoredImageSRC.length)
+ // console.log('inside start of flipped. $scope.ColoredImageSRC.length= ' + $scope.ColoredImageSRC.length)
$rootScope.isHighLight = true;
- console.log('just before highLightBody call');
+ //console.log('just before highLightBody call');
$scope.highLightBody();
- console.log('just after highLightBody call');
+ //console.log('just after highLightBody call');
//}, 500);
}
}
@@ -1679,7 +1679,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.MultiLanguageAnnationArray.push(annotationText);
- console.log('2. annotationText: ' + annotationText + ' , length: ' + $scope.MultiLanguageAnnationArray.length);
+ // console.log('2. annotationText: ' + annotationText + ' , length: ' + $scope.MultiLanguageAnnationArray.length);
$scope.createDynamicSpeechBubble(evt, evt.pageX + horizontlScrollPosition - $('#canvasDiv').offset().left, evt.pageY + verticalScrollPosition - $('#canvasDiv').offset().top, true);
@@ -1691,7 +1691,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.MultiLanguageAnnationArray = [];
$scope.MultiLanguageAnnationArray.push(annotationText);
- console.log('3. annotationText: ' + annotationText + ' , length: ' + $scope.MultiLanguageAnnationArray.length);
+ //console.log('3. annotationText: ' + annotationText + ' , length: ' + $scope.MultiLanguageAnnationArray.length);
$scope.createDynamicSpeechBubble(evt, evt.pageX + horizontlScrollPosition - $('#canvasDiv').offset().left, evt.pageY + verticalScrollPosition - $('#canvasDiv').offset().top, true);
}
@@ -1805,11 +1805,11 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$rootScope.isLoading = true;
$('#spinner').css('visibility', 'visible');
//$timeout(function () {
- console.log('inside start of non flipped. $scope.ColoredImageSRC.length= ' + $scope.ColoredImageSRC.length)
+ // console.log('inside start of non flipped. $scope.ColoredImageSRC.length= ' + $scope.ColoredImageSRC.length)
$rootScope.isHighLight = true;
- console.log('just before highLightBody call');
+ //console.log('just before highLightBody call');
$scope.highLightBody();
- console.log('just after highLightBody call');
+ //console.log('just after highLightBody call');
//}, 500);
}
}
@@ -1957,7 +1957,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
//push workers in array to further used the refernece to delete the workers
$scope.runningWorkers.push({ 'workerName': worker })
- console.log('for BRID = ' + bodyRegionId + ', coloredImageDataVar: ' + coloredImageDataVar + ', maskData= ' + maskData + ', white= ' + white)
+ //console.log('for BRID = ' + bodyRegionId + ', coloredImageDataVar: ' + coloredImageDataVar + ', maskData= ' + maskData + ', white= ' + white)
if (coloredImageDataVar != null && maskData != null && white != null) {
worker.postMessage({
@@ -2004,7 +2004,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
var canavsWidth = parseInt(grayCanvas.width);
var canavsHeight = parseInt(grayCanvas.height);
- console.log('canavsWidth= ' + canavsWidth + ', canavsHeight= ' + canavsHeight)
+ //console.log('canavsWidth= ' + canavsWidth + ', canavsHeight= ' + canavsHeight)
var imgData = grayCanvasContext.getImageData(0, 0, canavsWidth, canavsHeight);
var data = imgData.data;
@@ -5376,19 +5376,13 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
//1.
localStorage.setItem("genderId", 'Male');
- //2 first update the currentbodyviewid in local storage
- localStorage.setItem("currentBodyViewId", currentBodyViewId);
-
- //3.
+ //2.
$scope.loadSelectedBodyView(currentBodyViewId);
- //4.
+ //3.
$scope.loadSelectedBodyViewNavigator(currentBodyViewId);
- //5. change the search terms as per the selected bodyview
- $scope.loadSearchDataForBodyView();
- //6.
$('#daImagePanel')[0].childNodes[0].childNodes[0].innerHTML = localStorage.getItem("currentViewTitle").replace('Female', 'Male');
localStorage.setItem("currentViewTitle", localStorage.getItem("currentViewTitle").replace('Female', 'Male'));
@@ -5400,22 +5394,15 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
else if ((event.currentTarget.attributes[1].value == 'Female') && (localStorage.getItem("genderId") == 'Male')) {
- //1.
localStorage.setItem("genderId", 'Female');
- //2. first update the currentbodyviewid in local storage
- localStorage.setItem("currentBodyViewId", currentBodyViewId);
-
- //3.
+ //1.
$scope.loadSelectedBodyView(currentBodyViewId);
- //4.
+ //2.
$scope.loadSelectedBodyViewNavigator(currentBodyViewId);
- //5. change the search terms as per the selected bodyview
- $scope.loadSearchDataForBodyView();
-
- //6.
+ //3.
$('#daImagePanel')[0].childNodes[0].childNodes[0].innerHTML = localStorage.getItem("currentViewTitle").replace('Male', 'Female');
localStorage.setItem("currentViewTitle", localStorage.getItem("currentViewTitle").replace('Male', 'Female'));
@@ -5551,19 +5538,13 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$rootScope.voId = selectedViewId;
$rootScope.isLoading = true;
- //1. first update the currentbodyviewid in local storage
- localStorage.setItem("currentBodyViewId", $rootScope.voId);
-
- //2. Load selected body view
+ //1. Load selected body view
$scope.loadSelectedBodyView($rootScope.voId);
- //3. load corresponding navigator man
+ //2. load corresponding navigator man
$scope.loadSelectedBodyViewNavigator($rootScope.voId);
- //4. change the search terms as per the selected bodyview
- $scope.loadSearchDataForBodyView();
-
- //5.Change the popup title next to search
+ //3.Change the popup title next to search
$scope.currentTitleFromJson = localStorage.getItem("currentViewTitle");
};
@@ -5681,35 +5662,35 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
//console.log('reloadDABodyViewEvent');
$scope.layerNumber = parseInt($('#txtlayerNumber').val());
- //$scope.ReloadBodyViewId = data.reloadDABodyViewId;
+ $scope.ReloadBodyViewId = data.reloadDABodyViewId;
// $scope.layerNumber = 0;
// debugger;
- //console.log('reloadDABodyViewEvent ' + $scope.ReloadBodyViewId);
+ // console.log('reloadDABodyViewEvent ' + $scope.ReloadBodyViewId);
- //if ($rootScope.isSettingEventAlredayDispachted == true) {
+ if ($rootScope.isSettingEventAlredayDispachted == true) {
- $scope.loadSelectedBodyView(data.reloadDABodyViewId);
+ $scope.loadSelectedBodyView($scope.ReloadBodyViewId);
- $scope.loadSelectedBodyViewNavigator(data.reloadDABodyViewId);
+ $scope.loadSelectedBodyViewNavigator($scope.ReloadBodyViewId);
$scope.currentTitleFromJson = localStorage.getItem("currentViewTitle");
- //$rootScope.isSettingEventAlredayDispachted = false;
- //}
+ $rootScope.isSettingEventAlredayDispachted = false;
+ }
})
$scope.loadSelectedBodyViewNavigator = function (currentBodyViewId) {
- //$rootScope.voId = currentBodyViewId;
+ $rootScope.voId = currentBodyViewId;
- //$scope.skinTone = $rootScope.globalSetting.ethnicity;
+ $scope.skinTone = $rootScope.globalSetting.ethnicity;
if ($scope.NavigatorData != null || $scope.NavigatorData != undefined) {
var navdtlOrient = new jinqJs()
.from($scope.NavigatorData.Navigtor.ViewOrientation)
- .where("_ViewOrientationId == " + currentBodyViewId)
+ .where("_ViewOrientationId == " + $scope.voId)
.select();
@@ -5717,7 +5698,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
var navOrientationdata = new jinqJs()
.from(navdtlOrient[0].ImageInfo)
- .where("_Ethnicity == " + $rootScope.globalSetting.ethnicity)
+ .where("_Ethnicity == " + $scope.skinTone)
.select();
if (navOrientationdata != null || navOrientationdata != undefined) {
@@ -5738,7 +5719,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
}
- $scope.navimgsrc = "~/../content/images/DA/ethnicity/body-views/" + $scope.voId + '/' + $rootScope.globalSetting.ethnicity + '/navigator_images/' + navImageModesty;
+ $scope.navimgsrc = "~/../content/images/DA/ethnicity/body-views/" + $scope.voId + '/' + $scope.skinTone + '/navigator_images/' + navImageModesty;
}
}
@@ -5838,8 +5819,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
var canvasElement = document.getElementById("canvas");
var ctx = canvasElement.getContext("2d");
- var canvasElement1 = document.getElementById("canvasPaint");
- var ctx1 = canvasElement1.getContext("2d");
+
/* if ($rootScope.shapeType == "FreeStylePaint") {
var canvasPaint_zIndex = $('#canvasPaint').css("z-index");
@@ -5860,7 +5840,6 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
case "cursor":
// ctx.clearRect(0, 0, 2277, 3248);
ctx.beginPath();
- ctx1.beginPath();
break;
@@ -6004,7 +5983,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
break;
case "Circle":
- // alert($rootScope.shapestyleborderWidth);
+ // alert($rootScope.shapestyleFillColor);
$rootScope.resetCircle = $rootScope.ObjectIndex++;
$('#canvas').addLayer({
layer: true,
@@ -6372,7 +6351,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$rootScope.textArea = $("#text_area").val();
$("#canvas").removeLayer('TextArea_' + $rootScope.resetText).drawLayers();
$("#canvas").removeLayer("TextRect_" + $rootScope.resetTextRect).drawLayers();
-
+ // alert($rootScope.fontColor);
$('#canvas').drawText({
layer: true,
draggable: true,
@@ -6390,7 +6369,6 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
maxWidth: $scope.x - $scope.offsetX1,
maxHeight: $scope.y - $scope.offsetY1,
-
click: function (layer) {
@@ -6501,28 +6479,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
}
$scope.OnPaintBrushCanvasMouseDown = function (event) {
- switch ($rootScope.shapeType) {
-
- case "FreeStylePaint":
- debugger;
- $('#canvasPaint').sketch({ defaultSize: 1 });
- //if ($("#amount-2").val() == '') {
- // $('#canvasPaint').sketch({ defaultSize: $scope.shapesize });
- //}
- //else {
-
- // var a = $("#amount-2").val();
- // $scope.shapesize = parseInt(a);
- // // alert(JSON.stringify({ defaultSize: $scope.shapesize }));
- // $('#canvasPaint').sketch({ defaultSize: $scope.shapesize });
-
- //}
-
-
- break;
-
- }
}
$scope.OnPaintBrushCanvasMouseUp = function (event) {
@@ -6530,36 +6487,18 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
// var canvasElement1 = document.getElementById("canvasPaint");
// var ctx1 = canvasElement1.getContext("2d");
- //switch($rootScope.shapeType)
- //{
-
- // case "FreeStylePaint":
-
- // debugger;
-
- // if ($("#amount-2").val() == '')
- // {
- // $('#canvasPaint').sketch({ defaultSize: $scope.shapesize });
- // }
- // else
- // {
-
- // var a = $("#amount-2").val();
- // $scope.shapesize = parseInt(a);
- // alert(JSON.stringify({ defaultSize: $scope.shapesize }));
- // $('#canvasPaint').sketch({ defaultSize: $scope.shapesize });
+ switch ($rootScope.shapeType) {
+ case "FreeStylePaint":
- // }
+ $('#canvasPaint').sketch({ defaultSize: 1 });
+ break;
- // break;
- //}
+ }
}
-
-
$(document).keydown(function (event) {
@@ -6914,7 +6853,6 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
var systemList = $rootScope.CommonData.DACommonData.BodySystems.Item;
$('#bodySystems').empty();
-
var $all = $('').appendTo('#bodySystems');
$compile($all)($scope);
@@ -6941,7 +6879,6 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
//confirm that this is DA module which is last open
if (currentOpenModuleId == 1) {
-
$('#termList').empty();
$scope.loadListManger();
@@ -7135,10 +7072,11 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.flushCanvas();
-
//9.
$timeout(function () {
$rootScope.isHighLight = false;
+
+ //removing speechbubble
$('#sppeachBubble').css('display', 'none');
$("#dot").css("display", "none");