mirror of
https://github.com/zjs81/meshcore-open.git
synced 2026-06-14 22:55:12 +10:00
Add initial load scheduling and tests for USB screen and frame codec functionality
This commit is contained in:
committed by
just-stuff-tm
parent
781090243c
commit
f39a22668e
@@ -21,6 +21,7 @@ class _UsbScreenState extends State<UsbScreen> {
|
||||
bool _isLoadingPorts = true;
|
||||
bool _isConnecting = false;
|
||||
bool _navigatedToContacts = false;
|
||||
bool _didScheduleInitialLoad = false;
|
||||
String? _selectedPort;
|
||||
String? _errorText;
|
||||
late final MeshCoreConnector _connector;
|
||||
@@ -58,13 +59,16 @@ class _UsbScreenState extends State<UsbScreen> {
|
||||
}
|
||||
};
|
||||
_connector.addListener(_connectionListener);
|
||||
unawaited(_loadPorts());
|
||||
}
|
||||
|
||||
@override
|
||||
void didChangeDependencies() {
|
||||
super.didChangeDependencies();
|
||||
_connector.setUsbRequestPortLabel(context.l10n.usbScreenStatus);
|
||||
if (!_didScheduleInitialLoad) {
|
||||
_didScheduleInitialLoad = true;
|
||||
unawaited(_loadPorts());
|
||||
}
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
Reference in New Issue
Block a user