keepScreenOff method
Implementation
@override
Future<void> keepScreenOff() async {
if (_wakeLockSentinel == null) return;
try {
await _wakeLockSentinel!.release().toDart;
} catch (_) {}
_wakeLockSentinel = null;
await _visibilitySub?.cancel();
_visibilitySub = null;
}