Toggle navigation
Toggle navigation
This project
Loading...
Sign in
flutter_package
/
mobile_scanner
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
Ben White
2024-05-17 15:16:00 -0500
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
6f09ec32ed84beb06392e0ee913ae0ef41d1f621
6f09ec32
1 parent
c0ac2453
connecting the useNewCameraSelector option
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
0 deletions
lib/src/mobile_scanner_controller.dart
lib/src/objects/start_options.dart
lib/src/mobile_scanner_controller.dart
View file @
6f09ec3
...
...
@@ -268,6 +268,7 @@ class MobileScannerController extends ValueNotifier<MobileScannerState> {
formats:
formats
,
returnImage:
returnImage
,
torchEnabled:
torchEnabled
,
useNewCameraSelector:
useNewCameraSelector
,
);
try
{
...
...
lib/src/objects/start_options.dart
View file @
6f09ec3
...
...
@@ -14,6 +14,7 @@ class StartOptions {
required
this
.
formats
,
required
this
.
returnImage
,
required
this
.
torchEnabled
,
required
this
.
useNewCameraSelector
,
});
/// The direction for the camera.
...
...
@@ -37,6 +38,10 @@ class StartOptions {
/// Whether the torch should be turned on when the scanner starts.
final
bool
torchEnabled
;
/// Only supported on Android.
/// Whether the new resolution selector should be used.
final
bool
useNewCameraSelector
;
Map
<
String
,
Object
?>
toMap
()
{
return
<
String
,
Object
?>{
if
(
cameraResolution
!=
null
)
...
...
@@ -51,6 +56,7 @@ class StartOptions {
'speed'
:
detectionSpeed
.
rawValue
,
'timeout'
:
detectionTimeoutMs
,
'torch'
:
torchEnabled
,
'useNewCameraSelector'
:
useNewCameraSelector
,
};
}
}
...
...
Please
register
or
login
to post a comment