mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-08-28 16:01:30 +00:00
kivy on_resume: check self.has_pin_code()
This commit is contained in:
parent
1429c5b2bf
commit
4004b8085f
1 changed files with 10 additions and 5 deletions
|
@ -948,8 +948,12 @@ class ElectrumWindow(App):
|
||||||
|
|
||||||
def on_resume(self):
|
def on_resume(self):
|
||||||
now = time.time()
|
now = time.time()
|
||||||
if self.wallet and self.wallet.has_password() and now - self.pause_time > 5*60:
|
if self.wallet and self.has_pin_code() and now - self.pause_time > 5*60:
|
||||||
d = PincodeDialog(check_password=self.check_pin_code, on_success=None, on_failure=self.stop)
|
d = PincodeDialog(
|
||||||
|
self,
|
||||||
|
check_password=self.check_pin_code,
|
||||||
|
on_success=None,
|
||||||
|
on_failure=self.stop)
|
||||||
d.open()
|
d.open()
|
||||||
if self.nfcscanner:
|
if self.nfcscanner:
|
||||||
self.nfcscanner.nfc_enable()
|
self.nfcscanner.nfc_enable()
|
||||||
|
@ -1240,10 +1244,11 @@ class ElectrumWindow(App):
|
||||||
cb()
|
cb()
|
||||||
self.show_info(_("PIN updated") if new_password else _('PIN disabled'))
|
self.show_info(_("PIN updated") if new_password else _('PIN disabled'))
|
||||||
on_failure = lambda: self.show_error(_("PIN not updated"))
|
on_failure = lambda: self.show_error(_("PIN not updated"))
|
||||||
|
|
||||||
d = PincodeDialog(
|
d = PincodeDialog(
|
||||||
self, check_password=self.check_pin_code,
|
self,
|
||||||
on_success=on_success, on_failure=on_failure,
|
check_password=self.check_pin_code,
|
||||||
|
on_success=on_success,
|
||||||
|
on_failure=on_failure,
|
||||||
is_change=True,
|
is_change=True,
|
||||||
has_password = self.has_pin_code())
|
has_password = self.has_pin_code())
|
||||||
d.open()
|
d.open()
|
||||||
|
|
Loading…
Add table
Reference in a new issue