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
2024-01-03 17:13:27 +0100
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
a08dc6d8958e86d6f7c261fa715f6b3a84eda8c2
a08dc6d8
1 parent
6c46a25f
fix small align issue in example app
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
77 additions
and
75 deletions
example/lib/main.dart
example/lib/main.dart
View file @
a08dc6d
...
...
@@ -23,82 +23,84 @@ class MyHome extends StatelessWidget {
Widget
build
(
BuildContext
context
)
{
return
Scaffold
(
appBar:
AppBar
(
title:
const
Text
(
'Mobile Scanner Example'
)),
body:
Column
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
children:
[
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerListView
(),
),
);
},
child:
const
Text
(
'MobileScanner with ListView'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerWithController
(),
),
);
},
child:
const
Text
(
'MobileScanner with Controller'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerWithScanWindow
(),
),
);
},
child:
const
Text
(
'MobileScanner with ScanWindow'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerReturningImage
(),
),
);
},
child:
const
Text
(
'MobileScanner with Controller (returning image)'
,
body:
Center
(
child:
Column
(
mainAxisAlignment:
MainAxisAlignment
.
spaceAround
,
children:
[
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerListView
(),
),
);
},
child:
const
Text
(
'MobileScanner with ListView'
),
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerWithZoom
(),
),
);
},
child:
const
Text
(
'MobileScanner with zoom slider'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerPageView
(),
),
);
},
child:
const
Text
(
'MobileScanner pageView'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
BarcodeScannerWithOverlay
(),
),
);
},
child:
const
Text
(
'MobileScanner with Overlay'
),
),
],
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerWithController
(),
),
);
},
child:
const
Text
(
'MobileScanner with Controller'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerWithScanWindow
(),
),
);
},
child:
const
Text
(
'MobileScanner with ScanWindow'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerReturningImage
(),
),
);
},
child:
const
Text
(
'MobileScanner with Controller (returning image)'
,
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerWithZoom
(),
),
);
},
child:
const
Text
(
'MobileScanner with zoom slider'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
const
BarcodeScannerPageView
(),
),
);
},
child:
const
Text
(
'MobileScanner pageView'
),
),
ElevatedButton
(
onPressed:
()
{
Navigator
.
of
(
context
).
push
(
MaterialPageRoute
(
builder:
(
context
)
=>
BarcodeScannerWithOverlay
(),
),
);
},
child:
const
Text
(
'MobileScanner with Overlay'
),
),
],
),
),
);
}
...
...
Please
register
or
login
to post a comment