From 2278cfe4ffa9658377029d417f348a0b22402f84 Mon Sep 17 00:00:00 2001 From: Ian VanSchooten Date: Thu, 31 Oct 2024 09:44:22 -0400 Subject: [PATCH] Fix camera background opacity --- lib/screens/siteConfig/ScanQRScreen.dart | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/screens/siteConfig/ScanQRScreen.dart b/lib/screens/siteConfig/ScanQRScreen.dart index 78fc00fe..fffcdf47 100644 --- a/lib/screens/siteConfig/ScanQRScreen.dart +++ b/lib/screens/siteConfig/ScanQRScreen.dart @@ -79,7 +79,7 @@ class ScannerOverlay extends CustomPainter { @override void paint(Canvas canvas, Size size) { // we need to pass the size to the custom paint widget - final backgroundPath = Path()..addRect(Rect.largest); + final backgroundPath = Path()..addRect(Rect.fromLTWH(0, 0, size.width, size.height)); final cutoutPath = Path() ..addRRect( @@ -95,7 +95,7 @@ class ScannerOverlay extends CustomPainter { final backgroundPaint = Paint() ..color = Colors.black.withOpacity(0.5) ..style = PaintingStyle.fill - ..blendMode = BlendMode.dstOut; + ..blendMode = BlendMode.srcOver; final backgroundWithCutout = Path.combine( PathOperation.difference,