add lock pin state
This commit is contained in:
parent
8c1383bdd4
commit
86931bab5b
|
@ -149,11 +149,14 @@ class MyWalletsProvider with ChangeNotifier {
|
||||||
notifyListeners();
|
notifyListeners();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int lockPin = 0;
|
||||||
Future resetPinCode([int minutes = 15]) async {
|
Future resetPinCode([int minutes = 15]) async {
|
||||||
|
lockPin++;
|
||||||
|
final actualLock = lockPin;
|
||||||
await Future.delayed(
|
await Future.delayed(
|
||||||
Duration(seconds: configBox.get('isCacheChecked') ? minutes * 60 : 1));
|
Duration(seconds: configBox.get('isCacheChecked') ? minutes * 60 : 1));
|
||||||
log.i('reset pin code ...');
|
log.i('reset pin code, lock $actualLock ...');
|
||||||
pinCode = '';
|
if (actualLock == lockPin) pinCode = '';
|
||||||
}
|
}
|
||||||
|
|
||||||
void rebuildWidget() {
|
void rebuildWidget() {
|
||||||
|
|
|
@ -253,13 +253,6 @@ packages:
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.2.0"
|
version: "1.2.0"
|
||||||
cron:
|
|
||||||
dependency: "direct main"
|
|
||||||
description:
|
|
||||||
name: cron
|
|
||||||
url: "https://pub.dartlang.org"
|
|
||||||
source: hosted
|
|
||||||
version: "0.5.0"
|
|
||||||
cross_file:
|
cross_file:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
|
|
@ -81,7 +81,6 @@ dependencies:
|
||||||
ref: fixAndroidActivityVersion
|
ref: fixAndroidActivityVersion
|
||||||
dots_indicator: ^2.1.0
|
dots_indicator: ^2.1.0
|
||||||
web_socket_channel: ^2.2.0
|
web_socket_channel: ^2.2.0
|
||||||
cron: ^0.5.0
|
|
||||||
|
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
# flutter_launcher_icons: ^0.9.2
|
# flutter_launcher_icons: ^0.9.2
|
||||||
|
|
Loading…
Reference in New Issue