Commit aeeddd03fda92a66d95d8053594b7c6382f77185
Merge branch 'Enable/Disablle_Tbox_Merge' into Develop
Showing
3 changed files
with
102 additions
and
66 deletions
.gitignore
... | ... | @@ -33,7 +33,7 @@ _ReSharper*/ |
33 | 33 | *.vssscc |
34 | 34 | $tf*/ |
35 | 35 | 400-SOURCECODE/AIAHTML5.Web/AIAHTML5.Web.csproj.user |
36 | -300-PROTOTYPES/POC/AIAHTML5 | |
37 | -400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js.orig | |
38 | -400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js.orig | |
36 | +300-PROTOTYPES/POC/AIAHTML5 | |
37 | +400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js.orig | |
38 | +400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js.orig | |
39 | 39 | 400-SOURCECODE/AIAHTML5.Web/index.html.orig |
40 | 40 | \ No newline at end of file | ... | ... |
400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
... | ... | @@ -885,7 +885,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
885 | 885 | var isiOSSafari = (navigator.userAgent.match(/iPad/i)) ? true : false; |
886 | 886 | |
887 | 887 | //set scrollbars on canvas and hide loading label |
888 | - // $('#daLoaderLabel').css('visibility', 'hidden') | |
888 | + $('#daLoaderLabel').css('visibility', 'hidden') | |
889 | 889 | |
890 | 890 | $('#canvasDiv').css('overflow', 'scroll') |
891 | 891 | if (isiOSSafari) { |
... | ... | @@ -1369,6 +1369,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
1369 | 1369 | "haveMirror": 'true' |
1370 | 1370 | } |
1371 | 1371 | ); |
1372 | + } | |
1372 | 1373 | |
1373 | 1374 | |
1374 | 1375 | // console.log('$rootScope.isListManagerSelected= ' + $rootScope.isListManagerSelected + ' length= ' + $scope.ColoredImageSRC.length) |
... | ... | @@ -1398,7 +1399,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
1398 | 1399 | //$rootScope.isLoading = false; |
1399 | 1400 | //$('#spinner').css('visibility', 'hidden'); |
1400 | 1401 | |
1401 | - | |
1402 | + $scope.ColoredImageSRC.push | |
1402 | 1403 | $rootScope.isLoading = true; |
1403 | 1404 | $('#spinner').css('visibility', 'visible'); |
1404 | 1405 | //$timeout(function () { |
... | ... | @@ -1696,6 +1697,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
1696 | 1697 | } |
1697 | 1698 | |
1698 | 1699 | ); |
1700 | + } | |
1699 | 1701 | |
1700 | 1702 | |
1701 | 1703 | if (($scope.ColoredImageSRC != null || $scope.ColoredImageSRC != undefined)) { |
... | ... | @@ -3335,36 +3337,45 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
3335 | 3337 | |
3336 | 3338 | }; |
3337 | 3339 | |
3338 | - | |
3340 | + $rootScope.isTransparencyBoxActivated = false; | |
3339 | 3341 | $scope.createTransparencyBox = function () { |
3342 | + | |
3343 | + $rootScope.isTransparencyBoxActivated = true; | |
3344 | + | |
3345 | + if ($rootScope.isExtractButtonActive == false) { | |
3340 | 3346 | |
3341 | - | |
3342 | - //if listanager is visisble then close it | |
3343 | - | |
3347 | + //if listanager is visisble then close it | |
3348 | + $("#btnExtract").addClass("disabled"); | |
3344 | 3349 | $rootScope.isListManagerSelected = false; |
3345 | 3350 | $rootScope.CloseListManager(); |
3346 | 3351 | |
3347 | 3352 | |
3348 | - $scope.isTransparencyActivated = true; | |
3349 | - // alert('transparencyClicked' + $scope.isTransparencyActivated) | |
3350 | - $('#btnTranparency').addClass('tButtonActive'); | |
3351 | - $('#btnIdentity').removeClass(' btn-primary'); | |
3352 | - $('#btnIdentity').addClass('btn-black'); | |
3353 | + $scope.isTransparencyActivated = true; | |
3354 | + | |
3355 | + $('#btnTranparency').addClass('tButtonActive'); | |
3356 | + $('#btnIdentity').removeClass(' btn-primary'); | |
3357 | + $('#btnIdentity').addClass('btn-black'); | |
3353 | 3358 | |
3354 | - var canvasDiv = document.getElementById('canvasDiv'); | |
3355 | - $scope.verticalScrollPosition = canvasDiv.scrollTop; | |
3356 | - $scope.horizontlScrollPosition = canvasDiv.scrollLeft; | |
3359 | + var canvasDiv = document.getElementById('canvasDiv'); | |
3360 | + $scope.verticalScrollPosition = canvasDiv.scrollTop; | |
3361 | + $scope.horizontlScrollPosition = canvasDiv.scrollLeft; | |
3357 | 3362 | |
3358 | - var canvasDiv = document.getElementById('canvasDiv'); | |
3359 | - canvasDiv.addEventListener("mousedown", mouseDownListener); | |
3363 | + var canvasDiv = document.getElementById('canvasDiv'); | |
3364 | + canvasDiv.addEventListener("mousedown", mouseDownListener); | |
3360 | 3365 | |
3361 | - canvasDiv.addEventListener("mousemove", mouseMoveListener); | |
3366 | + canvasDiv.addEventListener("mousemove", mouseMoveListener); | |
3362 | 3367 | |
3363 | - canvasDiv.addEventListener("mouseup", mouseUpListener) | |
3368 | + canvasDiv.addEventListener("mouseup", mouseUpListener) | |
3364 | 3369 | |
3365 | 3370 | |
3366 | - } | |
3371 | + } | |
3372 | + else | |
3373 | + { | |
3374 | + | |
3375 | + // console.log("extract button is active"); | |
3367 | 3376 | |
3377 | + } | |
3378 | + } | |
3368 | 3379 | function mouseDownListener(e) { |
3369 | 3380 | //Dated:18-07-2016 Issue#4975: Transparency box should not be clickable if it is already selected. |
3370 | 3381 | var tCanvas = document.getElementById('transparencyCanvas'); |
... | ... | @@ -4444,7 +4455,8 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
4444 | 4455 | } |
4445 | 4456 | |
4446 | 4457 | $scope.CloseTransparencyBox = function () { |
4447 | - | |
4458 | + $rootScope.isTransparencyBoxActivated = false; | |
4459 | + $("#btnExtract").removeClass("disabled"); | |
4448 | 4460 | $('.com_anno').css('display', 'none'); |
4449 | 4461 | |
4450 | 4462 | $('#sppeachBubble_annotation').css('display', 'none'); |
... | ... | @@ -4808,13 +4820,22 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
4808 | 4820 | } |
4809 | 4821 | |
4810 | 4822 | $scope.enableNormalMode = function () { |
4823 | + | |
4824 | + | |
4811 | 4825 | |
4826 | + $rootScope.isExtractButtonActive = false; | |
4827 | + $("#btnTranparency").removeClass("disabled"); | |
4828 | + // console.log('enableNormalMode is called'); | |
4812 | 4829 | |
4813 | 4830 | //if listanager is visisble then close it |
4814 | 4831 | |
4815 | 4832 | // $rootScope.isListManagerSelected = false; |
4833 | + | |
4834 | + //to do should not call every time | |
4816 | 4835 | $rootScope.CloseListManager(); |
4817 | 4836 | |
4837 | + | |
4838 | + | |
4818 | 4839 | if ($rootScope.isNormalMode == true) { |
4819 | 4840 | |
4820 | 4841 | } |
... | ... | @@ -4863,70 +4884,82 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo |
4863 | 4884 | $("#btnHighLight").removeClass("btn-primary"); |
4864 | 4885 | } |
4865 | 4886 | } |
4866 | - | |
4887 | + $rootScope.isExtractButtonActive = false; | |
4867 | 4888 | $scope.enableExtract = function () { |
4889 | + if ($rootScope.isTransparencyBoxActivated == true) { | |
4868 | 4890 | |
4891 | + $("#btnExtract").addClass("disabled"); | |
4869 | 4892 | |
4893 | + } | |
4894 | + else | |
4895 | + { | |
4870 | 4896 | |
4871 | - //if listanager is visisble then close it | |
4897 | + //disable transparency button | |
4898 | + $rootScope.isExtractButtonActive = true; | |
4899 | + $("#btnTranparency").addClass("disabled"); | |
4900 | + | |
4901 | + //if listanager is visisble then close it | |
4872 | 4902 | |
4873 | 4903 | // $rootScope.isListManagerSelected = false; |
4874 | - $rootScope.CloseListManager(); | |
4875 | - //1. | |
4876 | - $rootScope.isLoading = true; | |
4877 | - $('#spinner').css('visibility', 'visible'); | |
4904 | + $rootScope.CloseListManager(); | |
4905 | + //1. | |
4906 | + $rootScope.isLoading = true; | |
4907 | + $('#spinner').css('visibility', 'visible'); | |
4878 | 4908 | |
4879 | - //2. | |
4880 | - $scope.terminateCurrentlyRunningWPs(); | |
4909 | + //2. | |
4910 | + $scope.terminateCurrentlyRunningWPs(); | |
4881 | 4911 | |
4882 | - //3. | |
4883 | - if ($rootScope.isExtract == true) { | |
4912 | + //3. | |
4913 | + if ($rootScope.isExtract == true) { | |
4884 | 4914 | |
4885 | - } | |
4886 | - else { | |
4887 | - $rootScope.isExtract = true; | |
4915 | + } | |
4916 | + else { | |
4917 | + $rootScope.isExtract = true; | |
4888 | 4918 | |
4889 | 4919 | |
4890 | - if ($rootScope.isNormalMode == true) { | |
4920 | + if ($rootScope.isNormalMode == true) { | |
4891 | 4921 | |
4892 | - $rootScope.isHighLight = false; | |
4893 | - $rootScope.isNormalMode = false; | |
4894 | - } | |
4895 | - else { | |
4896 | - $rootScope.isNormalMode = false; | |
4897 | - $rootScope.isHighLight = false; | |
4898 | - } | |
4922 | + $rootScope.isHighLight = false; | |
4923 | + $rootScope.isNormalMode = false; | |
4924 | + } | |
4925 | + else { | |
4926 | + $rootScope.isNormalMode = false; | |
4927 | + $rootScope.isHighLight = false; | |
4928 | + } | |
4899 | 4929 | |
4900 | - //4. | |
4901 | - console.log('highLightBody from enableExtract') | |
4902 | - $scope.highLightBody(); | |
4930 | + //4. | |
4931 | + console.log('highLightBody from enableExtract') | |
4932 | + $scope.highLightBody(); | |
4903 | 4933 | |
4904 | 4934 | |
4905 | - } | |
4935 | + } | |
4906 | 4936 | |
4907 | - //5. unhighlight other | |
4908 | - //$scope.Normal = ""; | |
4909 | - //$scope.Extract = "LeftButtonsDefaultState"; | |
4910 | - //$scope.Highlight = ""; | |
4937 | + //5. unhighlight other | |
4938 | + //$scope.Normal = ""; | |
4939 | + //$scope.Extract = "LeftButtonsDefaultState"; | |
4940 | + //$scope.Highlight = ""; | |
4911 | 4941 | |
4912 | - $("#btnExtract").addClass("btn-primary"); | |
4913 | - $("#btnExtract").removeClass("btn-black"); | |
4942 | + $("#btnExtract").addClass("btn-primary"); | |
4943 | + $("#btnExtract").removeClass("btn-black"); | |
4914 | 4944 | |
4915 | - if (!$("#btnNormalMode").hasClass("btn-black")) { | |
4916 | - $("#btnNormalMode").addClass("btn-black"); | |
4917 | - } | |
4945 | + if (!$("#btnNormalMode").hasClass("btn-black")) { | |
4946 | + $("#btnNormalMode").addClass("btn-black"); | |
4947 | + } | |
4918 | 4948 | |
4919 | - if (!$("#btnHighLight").hasClass("btn-black")) { | |
4920 | - $("#btnHighLight").addClass("btn-black"); | |
4921 | - } | |
4949 | + if (!$("#btnHighLight").hasClass("btn-black")) { | |
4950 | + $("#btnHighLight").addClass("btn-black"); | |
4951 | + } | |
4922 | 4952 | |
4923 | - if ($("#btnNormalMode").hasClass("btn-primary")) { | |
4924 | - $("#btnNormalMode").removeClass("btn-primary"); | |
4925 | - } | |
4953 | + if ($("#btnNormalMode").hasClass("btn-primary")) { | |
4954 | + $("#btnNormalMode").removeClass("btn-primary"); | |
4955 | + } | |
4956 | + | |
4957 | + if ($("#btnHighLight").hasClass("btn-primary")) { | |
4958 | + $("#btnHighLight").removeClass("btn-primary"); | |
4959 | + } | |
4926 | 4960 | |
4927 | - if ($("#btnHighLight").hasClass("btn-primary")) { | |
4928 | - $("#btnHighLight").removeClass("btn-primary"); | |
4929 | 4961 | } |
4962 | + | |
4930 | 4963 | } |
4931 | 4964 | |
4932 | 4965 | $scope.enableShowHideStructureBox = function () { | ... | ... |
400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
... | ... | @@ -127,6 +127,10 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", |
127 | 127 | console.log('close') |
128 | 128 | $(".annotationTollbar").css("display", "none"); |
129 | 129 | $rootScope.isAnnotationWindowClose = true; |
130 | + //Click is disabled within the image area if open annotation toolbar and and closing without doing anything | |
131 | + $("#canvasPaint").css("display", "none"); | |
132 | + $("#canvas").css("display", "none"); | |
133 | + | |
130 | 134 | } |
131 | 135 | |
132 | 136 | $rootScope.OnIdentifyClick = function () { |
... | ... | @@ -276,7 +280,6 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", |
276 | 280 | $rootScope.shapestyleborderWidth = intPart[0]; |
277 | 281 | $rootScope.shapestyleborderStyles = "solid"; |
278 | 282 | |
279 | - $('#editshapestyle').modal('hide'); | |
280 | 283 | } |
281 | 284 | |
282 | 285 | $rootScope.enableAnnotationToolBar = function () { | ... | ... |