Enhance BLE connection handling and improve USB connection messaging
- Wrapped BLE scan and connection methods in try-catch blocks to handle errors gracefully and provide debug output. - Added retry logic for service discovery on web platforms after transient disconnections. - Updated USB connection messages in multiple languages to reflect active support on Android and desktop platforms. - Improved loading indicators for contacts screen to show a spinner during data loading.
This commit is contained in:
1 parent
ee3af52c0f
commit
2d1160d992
31 files changed
+240
-140
No files matched your search
@@ -384,8 +384,15 @@ class _ContactsScreenState extends State<ContactsScreen>
|
||||
|
||||
Widget _buildContactsBody(BuildContext context, MeshCoreConnector connector) {
|
||||
final contacts = connector.contacts;
|
||||
final shouldShowStartupSpinner =
|
||||
contacts.isEmpty &&
|
||||
_groups.isEmpty &&
|
||||
connector.isConnected &&
|
||||
(connector.isLoadingContacts ||
|
||||
connector.isLoadingChannels ||
|
||||
connector.selfPublicKey == null);
|
||||
|
||||
if (contacts.isEmpty && connector.isLoadingContacts && _groups.isEmpty) {
|
||||
if (shouldShowStartupSpinner) {
|
||||
return const Center(child: CircularProgressIndicator());
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user