mirror of
https://github.com/immich-app/immich.git
synced 2024-11-24 08:52:28 +02:00
feat(mobile): enable wakelock on backup page (#11621)
This commit is contained in:
parent
1dae622dbc
commit
745e1b003d
@ -18,6 +18,7 @@ import 'package:immich_mobile/providers/websocket.provider.dart';
|
||||
import 'package:immich_mobile/routing/router.dart';
|
||||
import 'package:immich_mobile/widgets/backup/backup_info_card.dart';
|
||||
import 'package:immich_mobile/widgets/backup/current_backup_asset_info_box.dart';
|
||||
import 'package:wakelock_plus/wakelock_plus.dart';
|
||||
|
||||
@RoutePage()
|
||||
class BackupControllerPage extends HookConsumerWidget {
|
||||
@ -49,7 +50,11 @@ class BackupControllerPage extends HookConsumerWidget {
|
||||
ref
|
||||
.watch(websocketProvider.notifier)
|
||||
.stopListenToEvent('on_upload_success');
|
||||
return null;
|
||||
|
||||
WakelockPlus.enable();
|
||||
return () {
|
||||
WakelockPlus.disable();
|
||||
};
|
||||
},
|
||||
[],
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user