Browse Source

updated zxing cpp and minor improvements

pull/89/head
Khoren Markosyan 2 years ago
parent
commit
4c719a3f13
  1. 13
      lib/src/ui/reader_widget.dart
  2. 2
      src/zxing
  3. 20
      zxscanner/ios/Gemfile.lock
  4. 5
      zxscanner/ios/fastlane/Fastfile
  5. 3
      zxscanner/ios/fastlane/screenshots/en-US/keyword.strings
  6. 3
      zxscanner/ios/fastlane/screenshots/en-US/title.strings
  7. 9
      zxscanner/ios/fastlane/screenshots/framefile.json

13
lib/src/ui/reader_widget.dart

@ -390,9 +390,7 @@ class _ReaderWidgetState extends State<ReaderWidget>
child: Row(
mainAxisSize: MainAxisSize.min,
children: <Widget>[
if (widget.showFlashlight &&
isCameraReady &&
_isFlashAvailable)
if (widget.showFlashlight && _isFlashAvailable)
IconButton(
onPressed: _onFlashButtonTapped,
color: Colors.white,
@ -401,13 +399,13 @@ class _ReaderWidgetState extends State<ReaderWidget>
controller?.value.flashMode ?? FlashMode.off),
),
),
if (widget.showGallery && isCameraReady)
if (widget.showGallery)
IconButton(
onPressed: _onGalleryButtonTapped,
color: Colors.white,
icon: const Icon(Icons.photo_library),
),
if (widget.showToggleCamera && isCameraReady)
if (widget.showToggleCamera)
IconButton(
onPressed: _onCameraButtonTapped,
color: Colors.white,
@ -439,7 +437,7 @@ class _ReaderWidgetState extends State<ReaderWidget>
}
void _onFlashButtonTapped() {
FlashMode mode = controller!.value.flashMode;
FlashMode mode = controller?.value.flashMode ?? FlashMode.off;
if (mode == FlashMode.torch) {
mode = FlashMode.off;
} else {
@ -471,6 +469,9 @@ class _ReaderWidgetState extends State<ReaderWidget>
}
void _onCameraButtonTapped() {
if (cameras.isEmpty || controller == null) {
return;
}
final int cameraIndex = cameras.indexOf(controller!.description);
final int nextCameraIndex = (cameraIndex + 1) % cameras.length;
selectedCamera = cameras[nextCameraIndex];

2
src/zxing

@ -1 +1 @@
Subproject commit 72023ad3dded9f3f94b5d85bc10385e0cf76620a
Subproject commit 8fe95e2f71eeb0d01646a44e1a2f17a7ee853652

20
zxscanner/ios/Gemfile.lock

@ -1,15 +1,15 @@
GEM
remote: https://rubygems.org/
specs:
CFPropertyList (3.0.5)
CFPropertyList (3.0.6)
rexml
addressable (2.8.1)
public_suffix (>= 2.0.2, < 6.0)
artifactory (3.0.15)
atomos (0.1.3)
aws-eventstream (1.2.0)
aws-partitions (1.697.0)
aws-sdk-core (3.169.0)
aws-partitions (1.713.0)
aws-sdk-core (3.170.0)
aws-eventstream (~> 1, >= 1.0.2)
aws-partitions (~> 1, >= 1.651.0)
aws-sigv4 (~> 1.5)
@ -17,7 +17,7 @@ GEM
aws-sdk-kms (1.62.0)
aws-sdk-core (~> 3, >= 3.165.0)
aws-sigv4 (~> 1.1)
aws-sdk-s3 (1.118.0)
aws-sdk-s3 (1.119.1)
aws-sdk-core (~> 3, >= 3.165.0)
aws-sdk-kms (~> 1)
aws-sigv4 (~> 1.4)
@ -36,7 +36,7 @@ GEM
unf (>= 0.0.5, < 1.0.0)
dotenv (2.8.1)
emoji_regex (3.2.3)
excon (0.97.2)
excon (0.99.0)
faraday (1.10.3)
faraday-em_http (~> 1.0)
faraday-em_synchrony (~> 1.0)
@ -106,9 +106,9 @@ GEM
xcpretty (~> 0.3.0)
xcpretty-travis-formatter (>= 0.0.3)
gh_inspector (1.1.3)
google-apis-androidpublisher_v3 (0.32.0)
google-apis-androidpublisher_v3 (0.34.0)
google-apis-core (>= 0.9.1, < 2.a)
google-apis-core (0.9.5)
google-apis-core (0.11.0)
addressable (~> 2.5, >= 2.5.1)
googleauth (>= 0.16.2, < 2.a)
httpclient (>= 2.8.1, < 3.a)
@ -150,7 +150,7 @@ GEM
httpclient (2.8.3)
jmespath (1.6.2)
json (2.6.3)
jwt (2.6.0)
jwt (2.7.0)
memoist (0.16.2)
mini_magick (4.12.0)
mini_mime (1.1.2)
@ -178,7 +178,7 @@ GEM
faraday (>= 0.17.5, < 3.a)
jwt (>= 1.5, < 3.0)
multi_json (~> 1.10)
simctl (1.6.8)
simctl (1.6.10)
CFPropertyList
naturally
terminal-notifier (2.0.0)
@ -194,7 +194,7 @@ GEM
unf_ext
unf_ext (0.0.8.2)
unicode-display_width (1.8.0)
webrick (1.7.0)
webrick (1.8.1)
word_wrap (1.0.0)
xcodeproj (1.22.0)
CFPropertyList (>= 2.3.3, < 4.0)

5
zxscanner/ios/fastlane/Fastfile

@ -22,4 +22,9 @@ platform :ios do
frameit # brew install imagemagick
# upload_to_app_store(skip_binary_upload: true, skip_metadata: true)
end
desc "Upload screenshots to App Store"
lane :upload do
upload_to_app_store(skip_binary_upload: true, skip_metadata: true)
end
end

3
zxscanner/ios/fastlane/screenshots/en-US/keyword.strings

@ -1,3 +1,2 @@
"01_scanner_screen" = "SCAN";
"02_creator_screen" = "CREATE";
"03_help_screen" = "HELP";
"02_creator_screen" = "CREATE";

3
zxscanner/ios/fastlane/screenshots/en-US/title.strings

@ -1,3 +1,2 @@
"01_scanner_screen" = "Scan Barcodes";
"02_creator_screen" = "Create Your Barcodes";
"03_help_screen" = "Introduction To Barcodes";
"02_creator_screen" = "Create Your Barcodes";

9
zxscanner/ios/fastlane/screenshots/framefile.json

@ -8,8 +8,7 @@
"padding": 30,
"show_complete_frame": false,
"stack_title" : true,
"title_below_image": false,
"frame": "BLACK"
"title_below_image": false
},
"data": [
@ -24,12 +23,6 @@
"keyword": {
"color": "#26AD5E"
}
},
{
"filter": "03_help_screen",
"keyword": {
"color": "#394C82"
}
}
]
}

Loading…
Cancel
Save