setBackgroundKeepAlive method
Opts the session into a background keep-alive (wake + Wi-Fi locks / prevent-sleep) for off-device playback such as casting. Defaults to a no-op so platforms (and any that do not override it) are safe.
Implementation
@override
Future<void> setBackgroundKeepAlive(bool enabled) async {
await methodChannel.invokeMethod('setBackgroundKeepAlive', enabled);
}