mirror of
https://github.com/dz0ny/meshcore-sar.git
synced 2026-08-11 16:30:28 +00:00
Move BLE communication layer (command queue, frame parser/builder, protocol constants, data models) into a standalone reusable Dart package at ../meshcore_client. App model files become thin re-export wrappers, keeping all existing consumers working without import changes.
18 lines
616 B
Dart
18 lines
616 B
Dart
export 'package:meshcore_client/meshcore_client.dart'
|
|
show Contact, ContactType, ContactTelemetry, AdvertLocation;
|
|
|
|
import 'package:flutter/material.dart';
|
|
import '../l10n/app_localizations.dart';
|
|
import 'package:meshcore_client/meshcore_client.dart';
|
|
|
|
extension ContactLocalization on Contact {
|
|
/// Returns the localized display name for special contacts (e.g. Public Channel).
|
|
/// For all other contacts, returns [displayName].
|
|
String getLocalizedDisplayName(BuildContext context) {
|
|
if (isPublicChannel) {
|
|
return AppLocalizations.of(context)!.publicChannel;
|
|
}
|
|
return displayName;
|
|
}
|
|
}
|