Commit 9bd18a5a28260df893ca57edad0523d7c015d1b7

Authored by Mukul Rajput
1 parent acd0e040

this is for opacity on brush draw sketch

400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
@@ -372,7 +372,7 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", @@ -372,7 +372,7 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location",
372 $rootScope.shapeSize = parseInt(btnBrushSizeValue); 372 $rootScope.shapeSize = parseInt(btnBrushSizeValue);
373 $("#annotationpaintbrushsize").attr("data-size", $rootScope.shapeSize); 373 $("#annotationpaintbrushsize").attr("data-size", $rootScope.shapeSize);
374 374
375 - $("#annotationpaintbrushsize").attr("data-color", $rootScope.shapestyleFillColor); 375 + $("#annotationpaintbrushsize").attr("data-color", $rootScope.shapestyleColorWithOpacity);
376 376
377 377
378 378
@@ -475,6 +475,8 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", @@ -475,6 +475,8 @@ AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location",
475 $rootScope.shapestyleOpacity = $("#" + id).css('opacity'); 475 $rootScope.shapestyleOpacity = $("#" + id).css('opacity');
476 $("#shapeStyleDiv").parent().css("opacity", $rootScope.shapestyleOpacity); 476 $("#shapeStyleDiv").parent().css("opacity", $rootScope.shapestyleOpacity);
477 $rootScope.shapestyleFillColor = $("#" + id).css('background-color'); 477 $rootScope.shapestyleFillColor = $("#" + id).css('background-color');
  478 + $rootScope.shapeStyleColorRGBA = $rootScope.shapestyleFillColor.replace("rgb", "rgba");
  479 + $rootScope.shapestyleColorWithOpacity = $rootScope.shapeStyleColorRGBA.substring(0, $rootScope.shapeStyleColorRGBA.length - 1) + " " + "," + $rootScope.shapestyleOpacity + ")";
478 $("#shapeStyleDiv").css("background-color", $rootScope.shapestyleFillColor); 480 $("#shapeStyleDiv").css("background-color", $rootScope.shapestyleFillColor);
479 $rootScope.shapestyleborderColor = $("#" + id).parent().css("border-top-color"); 481 $rootScope.shapestyleborderColor = $("#" + id).parent().css("border-top-color");
480 // $("#shapeStyleDiv").parent().css("border-color", $rootScope.shapestyleborderColor); 482 // $("#shapeStyleDiv").parent().css("border-color", $rootScope.shapestyleborderColor);