diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js index 6f0e2cb..fd51bbf 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js @@ -490,34 +490,38 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", $rootScope.shapestyleborderWidth = 2; $rootScope.shapestyleborderStyles = "solid"; $rootScope.shapestyle = function (id) { - // debugger; - document.getElementById('modelbackground').style.display = "none"; - document.getElementById('modeleditstyle').style.display = "none"; - - $rootScope.shapestyleOpacity = $("#" + id).css('opacity'); - $("#shapeStyleDiv").parent().css("opacity", $rootScope.shapestyleOpacity); - $rootScope.shapestyleFillColor = $("#" + id).css('background-color'); - $("#shapeStyleDiv").css("background-color", $rootScope.shapestyleFillColor); - $rootScope.shapestyleborderColor = $("#" + id).parent().css("border-top-color"); - $("#shapeStyleDiv").parent().css("border-color", $rootScope.shapestyleborderColor); - $rootScope.shapestyleborderWidthSeparatingPixel = $("#" + id).parent().css("border-top-width"); - $("#shapeStyleDiv").parent().css("border-width", $rootScope.shapestyleborderWidthSeparatingPixel); - var pixelSeparation = $rootScope.shapestyleborderWidthSeparatingPixel; - var intPart = pixelSeparation.split("p"); + + if ((document.getElementById('fill-option').checked == false) && (document.getElementById('Outline-Option').checked == false)) { + // $('#btnShapeStyle').attr('disabled', 'disabled'); + } else { + //$('#btnShapeStyle').removeAttr('disabled', 'disabled'); + document.getElementById('modelbackground').style.display = "none"; + document.getElementById('modeleditstyle').style.display = "none"; - $rootScope.shapestyleborderWidth = intPart[0]; - $rootScope.shapestyleborderStyles = "solid"; + $rootScope.shapestyleOpacity = $("#" + id).css('opacity'); + $("#shapeStyleDiv").parent().css("opacity", $rootScope.shapestyleOpacity); + $rootScope.shapestyleFillColor = $("#" + id).css('background-color'); + $("#shapeStyleDiv").css("background-color", $rootScope.shapestyleFillColor); + $rootScope.shapestyleborderColor = $("#" + id).parent().css("border-top-color"); + $("#shapeStyleDiv").parent().css("border-color", $rootScope.shapestyleborderColor); + $rootScope.shapestyleborderWidthSeparatingPixel = $("#" + id).parent().css("border-top-width"); + $("#shapeStyleDiv").parent().css("border-width", $rootScope.shapestyleborderWidthSeparatingPixel); + var pixelSeparation = $rootScope.shapestyleborderWidthSeparatingPixel; + var intPart = pixelSeparation.split("p"); + $rootScope.shapestyleborderWidth = intPart[0]; + $rootScope.shapestyleborderStyles = "solid"; - $('#editshapestyle').modal('hide'); - // name: 'Circle_' + $rootScope.resetCircle, + $('#editshapestyle').modal('hide'); + // name: 'Circle_' + $rootScope.resetCircle, - // $("#canvas").removeLayer("TextRect_" + $rootScope.resetTextRect).drawLayers(); - //Edit Shape Style popup should open at it's default position - $("#modeleditstyle").css({ "left": "40%", "right": "0", "top": "70px" }); + // $("#canvas").removeLayer("TextRect_" + $rootScope.resetTextRect).drawLayers(); + //Edit Shape Style popup should open at it's default position + $("#modeleditstyle").css({ "left": "40%", "right": "0", "top": "70px" }); + } } $rootScope.enableAnnotationToolBar = function () { diff --git a/400-SOURCECODE/AIAHTML5.Web/index.html b/400-SOURCECODE/AIAHTML5.Web/index.html index 7b20735..1657409 100644 --- a/400-SOURCECODE/AIAHTML5.Web/index.html +++ b/400-SOURCECODE/AIAHTML5.Web/index.html @@ -886,7 +886,7 @@ -->