Connect a radio: one page with Bluetooth, USB and TCP tabs
Replace the scanner, USB and TCP screens with one page and a tab for each, so the design and the connection options are consistent. Fixes #699, where the USB screen's Bluetooth button went back to the main screens instead of the scanner. The "Need a new node?" banner shows on every tab, with a close button that hides it until the page is opened again. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
86b3e252c6
commit
9104b4a60a
60 files changed
+989
-1474
No files matched your search
@@ -52,6 +52,7 @@ import 'package:meshcore_open/screens/repeater_cli_screen.dart';
|
||||
import 'package:meshcore_open/screens/repeater_hub_screen.dart';
|
||||
import 'package:meshcore_open/screens/repeater_settings_screen.dart';
|
||||
import 'package:meshcore_open/screens/repeater_status_screen.dart';
|
||||
import 'package:meshcore_open/screens/connect_screen.dart';
|
||||
import 'package:meshcore_open/screens/scanner_screen.dart';
|
||||
import 'package:meshcore_open/screens/settings_screen.dart';
|
||||
import 'package:meshcore_open/screens/tcp_screen.dart';
|
||||
@@ -244,6 +245,7 @@ final Map<String, _ScreenBuilder> _screens = {
|
||||
'Contacts add page': (_) => const ContactsScreen(),
|
||||
'AddContact': (_) => const AddContactScreen(),
|
||||
'Routing sheet': (c) => ChatScreen(contact: _contactOfType(c, advTypeChat)),
|
||||
'Connect': (_) => const ConnectScreen(),
|
||||
'Scanner': (_) => const ScannerScreen(),
|
||||
'Tcp': (_) => const TcpScreen(),
|
||||
'Usb': (_) => const UsbScreen(),
|
||||
@@ -333,7 +335,11 @@ void main() {
|
||||
);
|
||||
|
||||
setUpAll(() async {
|
||||
SharedPreferences.setMockInitialValues({});
|
||||
// A cached banner record, so the connect screen shows its banner.
|
||||
SharedPreferences.setMockInitialValues({
|
||||
'node_banner_txt': 'v=1;on=1;url=https://example.com/node',
|
||||
'node_banner_expires_ms': DateTime(2100).millisecondsSinceEpoch,
|
||||
});
|
||||
PrefsManager.reset();
|
||||
await PrefsManager.initialize();
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user