mirror of
https://github.com/HendrikRauh/inventree-app.git
synced 2026-01-13 03:26:24 +00:00
Screen wake (#565)
* Prevent screen turning off when scanning barcodes - Close https://github.com/inventree/inventree-app/issues/492 * Update release notes
This commit is contained in:
parent
6f5fc1d8a9
commit
707d251853
4 changed files with 35 additions and 1 deletions
|
|
@ -3,7 +3,7 @@ import "package:flutter/material.dart";
|
|||
import "package:flutter_tabler_icons/flutter_tabler_icons.dart";
|
||||
import "package:inventree/app_colors.dart";
|
||||
import "package:inventree/preferences.dart";
|
||||
|
||||
import "package:wakelock_plus/wakelock_plus.dart";
|
||||
import "package:flutter_zxing/flutter_zxing.dart";
|
||||
|
||||
import "package:inventree/l10.dart";
|
||||
|
|
@ -38,6 +38,13 @@ class _CameraBarcodeControllerState extends InvenTreeBarcodeControllerState {
|
|||
void initState() {
|
||||
super.initState();
|
||||
_loadSettings();
|
||||
WakelockPlus.enable();
|
||||
}
|
||||
|
||||
@override
|
||||
void dispose() {
|
||||
super.dispose();
|
||||
WakelockPlus.disable();
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue