electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 2d17dbb10c73cc5129c312c1df8a519a696de760
parent 4af1c2cbc4c92a41581bae5c723a34c1981ef13a
Author: ThomasV <thomasv@electrum.org>
Date:   Sat,  5 Mar 2016 09:44:28 +0100

kivy: receive_screen.clear

Diffstat:
Mgui/kivy/main_window.py | 2+-
Mgui/kivy/uix/screens.py | 8++++++--
2 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/gui/kivy/main_window.py b/gui/kivy/main_window.py @@ -497,7 +497,7 @@ class ElectrumWindow(App): # Once GUI has been initialized check if we want to announce something # since the callback has been called before the GUI was initialized if self.receive_screen: - self.receive_screen.screen.address = '' + self.receive_screen.clear() self.update_tabs() self.notify_transactions() run_hook('load_wallet', wallet, self) diff --git a/gui/kivy/uix/screens.py b/gui/kivy/uix/screens.py @@ -320,13 +320,17 @@ class ReceiveScreen(CScreen): status = self.app.wallet.get_request_status(self.screen.address) self.screen.status = _('Payment received') if status == PR_PAID else '' + def clear(self): + self.screen.address = '' + self.screen.amount = '' + self.screen.message = '' + def get_new_address(self): addr = self.app.wallet.get_unused_address(None) if addr is None: return False + self.clear() self.screen.address = addr - self.screen.amount = '' - self.screen.message = '' return True def on_address(self, addr):