Committed by
GitHub
feat: change platform os detect pattern in barcode_scanner_window.dart
Showing
1 changed file
with
1 additions
and
1 deletions
| @@ -204,7 +204,7 @@ class BarcodeOverlay extends CustomPainter { | @@ -204,7 +204,7 @@ class BarcodeOverlay extends CustomPainter { | ||
| 204 | final double ratioWidth; | 204 | final double ratioWidth; |
| 205 | final double ratioHeight; | 205 | final double ratioHeight; |
| 206 | 206 | ||
| 207 | - if (!kIsWeb && Platform.isIOS) { | 207 | + if (!kIsWeb && defaultTargetPlatform == TargetPlatform.iOS) { |
| 208 | ratioWidth = barcodeSize.width / adjustedSize.destination.width; | 208 | ratioWidth = barcodeSize.width / adjustedSize.destination.width; |
| 209 | ratioHeight = barcodeSize.height / adjustedSize.destination.height; | 209 | ratioHeight = barcodeSize.height / adjustedSize.destination.height; |
| 210 | } else { | 210 | } else { |
-
Please register or login to post a comment