fix: do not call WakeLock on Web (mobile) (#7668)
* fix: do not call WakeLock on Web (mobile) * fix: do not call WakeLock on Web (mobile) - replaced isMobile by !isWeb
This commit is contained in:
parent
6ba6a16836
commit
c972452310
@ -68,7 +68,9 @@ class _RemotePageState extends State<RemotePage> {
|
|||||||
gFFI.dialogManager
|
gFFI.dialogManager
|
||||||
.showLoading(translate('Connecting...'), onCancel: closeConnection);
|
.showLoading(translate('Connecting...'), onCancel: closeConnection);
|
||||||
});
|
});
|
||||||
WakelockPlus.enable();
|
if (!isWeb) {
|
||||||
|
WakelockPlus.enable();
|
||||||
|
}
|
||||||
_physicalFocusNode.requestFocus();
|
_physicalFocusNode.requestFocus();
|
||||||
gFFI.inputModel.listenToMouse(true);
|
gFFI.inputModel.listenToMouse(true);
|
||||||
gFFI.qualityMonitorModel.checkShowQualityMonitor(sessionId);
|
gFFI.qualityMonitorModel.checkShowQualityMonitor(sessionId);
|
||||||
@ -95,7 +97,9 @@ class _RemotePageState extends State<RemotePage> {
|
|||||||
gFFI.dialogManager.dismissAll();
|
gFFI.dialogManager.dismissAll();
|
||||||
await SystemChrome.setEnabledSystemUIMode(SystemUiMode.manual,
|
await SystemChrome.setEnabledSystemUIMode(SystemUiMode.manual,
|
||||||
overlays: SystemUiOverlay.values);
|
overlays: SystemUiOverlay.values);
|
||||||
await WakelockPlus.disable();
|
if (!isWeb) {
|
||||||
|
await WakelockPlus.disable();
|
||||||
|
}
|
||||||
await keyboardSubscription.cancel();
|
await keyboardSubscription.cancel();
|
||||||
removeSharedStates(widget.id);
|
removeSharedStates(widget.id);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user