This commit is contained in:
Forrest 2026-08-06 21:32:28 -04:00
parent b6639fb1c9
commit 0a7af1d813
10 changed files with 743 additions and 35 deletions

View file

@ -24,7 +24,7 @@ class RemoteControlState {
this.remoteState,
});
/// Whether this platform can host/discover at all (mobile + macOS).
/// Whether this platform can host/discover at all (mobile, macOS, Linux).
final bool supported;
/// This device is published as a controllable player.
@ -114,7 +114,11 @@ class RemoteControlController extends StateNotifier<RemoteControlState> {
PlaybackCommands? get remoteCommands => _proxy;
static bool _supported() =>
!kIsWeb && (Platform.isAndroid || Platform.isIOS || Platform.isMacOS);
!kIsWeb &&
(Platform.isAndroid ||
Platform.isIOS ||
Platform.isMacOS ||
Platform.isLinux);
/// Mutate state only while still mounted. Async hosting/session callbacks can
/// resolve after the provider is disposed (e.g. app teardown); touching
@ -274,6 +278,7 @@ class RemoteControlController extends StateNotifier<RemoteControlState> {
if (Platform.isIOS) return 'iOS device';
if (Platform.isAndroid) return 'Android device';
if (Platform.isMacOS) return 'Mac';
if (Platform.isLinux) return 'Linux';
return 'Timbre';
}