1
0

show unmatured coins in status bar. fixes #1163

This commit is contained in:
ThomasV
2015-05-05 20:52:14 +02:00
parent 4bce96526b
commit 687cc7783f
8 changed files with 74 additions and 52 deletions

View File

@@ -1122,9 +1122,12 @@ class ElectrumWindow:
text = "Synchronizing..."
else:
self.status_image.set_from_stock(Gtk.STOCK_YES, Gtk.IconSize.MENU)
c, u = self.wallet.get_balance()
text = "Balance: %s "%( format_satoshis(c,False,self.num_zeros) )
if u: text += "[%s unconfirmed]"%( format_satoshis(u,True,self.num_zeros).strip() )
c, u, x = self.wallet.get_balance()
text = "Balance: %s "%(format_satoshis(c, False, self.num_zeros))
if u:
text += "[%s unconfirmed]"%(format_satoshis(u, True, self.num_zeros).strip())
if x:
text += "[%s unmatured]"%(format_satoshis(x, True, self.num_zeros).strip())
else:
self.status_image.set_from_stock(Gtk.STOCK_NO, Gtk.IconSize.MENU)
self.network_button.set_tooltip_text("Not connected.")
@@ -1148,13 +1151,13 @@ class ElectrumWindow:
if self.wallet.is_change(address): Type = "C"
if address in self.wallet.imported_keys.keys():
Type = "I"
c, u = self.wallet.get_addr_balance(address)
c, u, x = self.wallet.get_addr_balance(address)
if address in self.wallet.frozen_addresses: Type = Type + "F"
label = self.wallet.labels.get(address)
h = self.wallet.history.get(address,[])
n = len(h)
tx = "0" if n==0 else "%d"%n
self.recv_list.append((address, label, tx, format_satoshis(c,False,self.num_zeros), Type ))
self.recv_list.append((address, label, tx, format_satoshis(c+u+x, False, self.num_zeros), Type ))
def update_sending_tab(self):
self.addressbook_list.clear()