diff options
author | uvok | 2025-07-31 13:49:06 +0200 |
---|---|---|
committer | uvok | 2025-07-31 13:49:06 +0200 |
commit | 2cd4bfa1410f5a079f74fd70aff3e9bc8ebe869f (patch) | |
tree | 51127253a3ce901bd82858d293d8adffde7eecd2 /lib | |
parent | fc9ee156c61738c7ceb77ddf82e79a6bcefb8d38 (diff) |
scan: Move SB down
Diffstat (limited to 'lib')
-rw-r--r-- | lib/widgets/scan_page.dart | 72 |
1 files changed, 36 insertions, 36 deletions
diff --git a/lib/widgets/scan_page.dart b/lib/widgets/scan_page.dart index 00283d2..dbc64dc 100644 --- a/lib/widgets/scan_page.dart +++ b/lib/widgets/scan_page.dart @@ -81,26 +81,26 @@ class _ScanPageState extends State<ScanPage> { @override Widget build(BuildContext context) { - return StreamBuilder( - stream: widget.deviceScanner.statusStream, - initialData: ScanStatus.idle, - builder: (context, asyncSnapshot) { - bool isScanning = asyncSnapshot.data == ScanStatus.scanning; - return Scaffold( - appBar: AppBar( - backgroundColor: Theme.of(context).colorScheme.inversePrimary, - title: Text(widget.title), - ), - body: Center( - child: Column( - // TRY THIS: Invoke "debug painting" (choose the "Toggle Debug Paint" - // action in the IDE, or press "p" in the console), to see the - // wireframe for each widget. - mainAxisAlignment: MainAxisAlignment.center, - spacing: 24, - children: <Widget>[ - SizedBox(height: 15), - Row( + return Scaffold( + appBar: AppBar( + backgroundColor: Theme.of(context).colorScheme.inversePrimary, + title: Text(widget.title), + ), + body: Center( + child: Column( + // TRY THIS: Invoke "debug painting" (choose the "Toggle Debug Paint" + // action in the IDE, or press "p" in the console), to see the + // wireframe for each widget. + mainAxisAlignment: MainAxisAlignment.center, + spacing: 24, + children: <Widget>[ + SizedBox(height: 15), + StreamBuilder( + stream: widget.deviceScanner.statusStream, + initialData: ScanStatus.idle, + builder: (context, asyncSnapshot) { + bool isScanning = asyncSnapshot.data == ScanStatus.scanning; + return Row( mainAxisAlignment: MainAxisAlignment.center, spacing: 15.0, children: [ @@ -117,24 +117,24 @@ class _ScanPageState extends State<ScanPage> { child: Text("Connect"), ), ], - ), - StreamBuilder( - stream: widget.deviceScanner.scanResultsStream, - initialData: <Device>[], - builder: (context, asyncSnapshot) { - return DeviceScanSelection( - items: asyncSnapshot.data ?? [], - onItemSelected: (item) { - setState(() => selectedDevice = item); - }, - ); + ); + }, + ), + StreamBuilder( + stream: widget.deviceScanner.scanResultsStream, + initialData: <Device>[], + builder: (context, asyncSnapshot) { + return DeviceScanSelection( + items: asyncSnapshot.data ?? [], + onItemSelected: (item) { + setState(() => selectedDevice = item); }, - ), - ], + ); + }, ), - ), - ); - }, + ], + ), + ), ); } } |