detect gaps for change too

This commit is contained in:
ecdsa 2013-03-16 18:24:45 +01:00
parent d6952228be
commit cce4a6c001
1 changed files with 6 additions and 7 deletions

View File

@ -1094,13 +1094,12 @@ class ElectrumWindow(QMainWindow):
for address in account[is_change]: for address in account[is_change]:
h = self.wallet.history.get(address,[]) h = self.wallet.history.get(address,[])
if not is_change: if h == []:
if h == []: gap += 1
gap += 1 if gap > self.wallet.gap_limit:
if gap > self.wallet.gap_limit: is_red = True
is_red = True else:
else: gap = 0
gap = 0
num_tx = '*' if h == ['*'] else "%d"%len(h) num_tx = '*' if h == ['*'] else "%d"%len(h)
item = QTreeWidgetItem( [ address, '', '', num_tx] ) item = QTreeWidgetItem( [ address, '', '', num_tx] )