keepAwake static method
Keeps the process alive and the machine awake while downloads run. On Android this is a
dataSync foreground service whose notification shows title, text and progress (0-100,
or -1 for indeterminate); elsewhere it is a power assertion or a background-task grant.
Implementation
static Future<void> keepAwake({required bool enabled, String? title, String? text, int progress = -1}) async =>
_call<void>("keepAwake", <String, Object?>{"enabled": enabled, "title": title, "text": text, "progress": progress});