electrum

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

commit 0933f57e18fef6eff07db7a9018b4cee48542235
parent ff152141aea161d80a1e127a57a29b3e2014e765
Author: ThomasV <thomasv@gitorious>
Date:   Sat,  4 Apr 2015 22:03:39 +0200

minor fix (UserRole)

Diffstat:
Mgui/qt/main_window.py | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/gui/qt/main_window.py b/gui/qt/main_window.py @@ -1442,7 +1442,7 @@ class ElectrumWindow(QMainWindow): def update_address_tab(self): l = self.address_list item = l.currentItem() - current_address = item.data(0, Qt.UserRole+1).toString() if item else None + current_address = item.data(0, Qt.UserRole).toString() if item else None l.clear() accounts = self.wallet.get_accounts() if self.current_account is None: @@ -1499,14 +1499,14 @@ class ElectrumWindow(QMainWindow): def update_contacts_tab(self): l = self.contacts_list item = l.currentItem() - current_address = item.data(0, Qt.UserRole+1).toString() if item else None + current_address = item.data(0, Qt.UserRole).toString() if item else None l.clear() for address in self.wallet.addressbook: label = self.wallet.labels.get(address,'') n = self.wallet.get_num_tx(address) item = QTreeWidgetItem( [ address, label, "%d"%n] ) item.setFont(0, QFont(MONOSPACE_FONT)) - item.setData(0, Qt.UserRole+1, address) + item.setData(0, Qt.UserRole, address) item.setData(0, Qt.UserRole+1, True) l.addTopLevelItem(item) if address == current_address: