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
Navaron Bracke
2022-12-11 20:27:39 +0100
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
61febbbc0d36781c612ed89f6a08d27035a18911
61febbbc
1 parent
1629e159
use error builder typedef; fix error type
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletions
lib/src/mobile_scanner.dart
lib/src/mobile_scanner.dart
View file @
61febbb
...
...
@@ -7,6 +7,13 @@ import 'package:mobile_scanner/src/mobile_scanner_exception.dart';
import
'package:mobile_scanner/src/objects/barcode_capture.dart'
;
import
'package:mobile_scanner/src/objects/mobile_scanner_arguments.dart'
;
/// The function signature for the error builder.
typedef
MobileScannerErrorBuilder
=
Widget
Function
(
BuildContext
,
MobileScannerException
,
Widget
?,
);
/// The [MobileScanner] widget displays a live camera preview.
class
MobileScanner
extends
StatefulWidget
{
/// The controller that manages the barcode scanner.
...
...
@@ -19,7 +26,7 @@ class MobileScanner extends StatefulWidget {
///
/// If this is null, defaults to a black [ColoredBox]
/// with a centered white [Icons.error] icon.
final
Widget
Function
(
BuildContext
,
Object
,
Widget
?)
?
errorBuilder
;
final
MobileScannerErrorBuilder
?
errorBuilder
;
/// The [BoxFit] for the camera preview.
///
...
...
Please
register
or
login
to post a comment