Browse Source

delete_imported_key method

283
ecdsa 12 years ago
parent
commit
fe405c50d0
  1. 3
      gui/gui_classic.py
  2. 7
      lib/wallet.py

3
gui/gui_classic.py

@ -971,10 +971,9 @@ class ElectrumWindow(QMainWindow):
def delete_imported_key(self, addr):
if self.question(_("Do you want to remove")+" %s "%addr +_("from your wallet?")):
self.wallet.imported_keys.pop(addr)
self.wallet.delete_imported_key(addr)
self.update_receive_tab()
self.update_history_tab()
self.wallet.save()
def create_receive_menu(self, position):

7
lib/wallet.py

@ -147,6 +147,11 @@ class Wallet:
self.config.set_key('imported_keys', self.imported_keys, True)
return address
def delete_imported_key(self, addr):
if addr in self.imported_keys:
self.imported_keys.pop(addr)
self.config.set_key('imported_keys', self.imported_keys, True)
def init_seed(self, seed):
if self.seed: raise BaseException("a seed exists")
@ -318,7 +323,7 @@ class Wallet:
def change_gap_limit(self, value):
if value >= self.gap_limit:
self.gap_limit = value
self.save()
self.config.set_key('gap_limit', self.gap_limit, True)
self.interface.poke('synchronizer')
return True

Loading…
Cancel
Save