electrum

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

commit 9325f47543d799a623d1cd76f496b46f910fc421
parent 0ac3ac8d610b0a60858b6a30ccf15dea5f7909a2
Author: ThomasV <thomasv@gitorious>
Date:   Wed,  7 Dec 2011 22:11:35 +0100

hide fee if there's no amount

Diffstat:
Mclient/gui.py | 5++++-
1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/client/gui.py b/client/gui.py @@ -45,7 +45,7 @@ def numbify(entry, is_int = False): try: amount = int( Decimal(s) * 100000000 ) except: - amount = 0 + amount = None entry.set_text(s) return amount @@ -587,6 +587,8 @@ class BitcoinGUI: amount = numbify(amount_entry) fee = numbify(fee_entry) if not is_fee: fee = None + if amount is None: + self.fee_box.hide(); return inputs, total, fee = self.wallet.choose_tx_inputs( amount, fee ) if not is_fee: fee_entry.set_text( str( Decimal( fee ) / 100000000 ) ) @@ -595,6 +597,7 @@ class BitcoinGUI: amount_entry.modify_text(gtk.STATE_NORMAL, gtk.gdk.color_parse("#000000")) fee_entry.modify_text(gtk.STATE_NORMAL, gtk.gdk.color_parse("#000000")) send_button.set_sensitive(True) + self.error = '' else: send_button.set_sensitive(False) amount_entry.modify_text(gtk.STATE_NORMAL, gtk.gdk.color_parse("#cc0000"))