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
Julian Steenbakker
2025-04-21 11:33:21 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
c0207b2a8ee29de73f02095036cae45caf023172
c0207b2a
1 parent
229d9ad6
hotfix: fix on detect not working when controller is provided
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
lib/src/mobile_scanner.dart
lib/src/mobile_scanner.dart
View file @
c0207b2
...
...
@@ -278,12 +278,16 @@ class _MobileScannerState extends State<MobileScanner>
if
(
widget
.
controller
==
null
)
{
WidgetsBinding
.
instance
.
addObserver
(
this
);
}
if
(
widget
.
onDetect
!=
null
)
{
_subscription
=
controller
.
barcodes
.
listen
(
widget
.
onDetect
,
onError:
widget
.
onDetectError
,
cancelOnError:
false
,
);
}
if
(
controller
.
autoStart
)
{
await
controller
.
start
();
}
...
...
Please
register
or
login
to post a comment