commit 41ef9aa4f74608566c191eb61fb82dee0655cf3a
parent b271483ee10efbf14541542bb4725eb096b42543
Author: ThomasV <thomasv@gitorious>
Date: Sun, 10 Jun 2012 15:57:38 +0200
menu action: paste tx ID to clipboard
Diffstat:
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/lib/gui_qt.py b/lib/gui_qt.py
@@ -272,14 +272,15 @@ class ElectrumWindow(QMainWindow):
def create_history_menu(self, position):
self.history_list.selectedIndexes()
item = self.history_list.currentItem()
+ tx_hash = str(item.toolTip(0))
if not item: return
menu = QMenu()
- menu.addAction(_("Details"), lambda: self.tx_details(item,2))
+ menu.addAction(_("Copy ID to Clipboard"), lambda: self.app.clipboard().setText(tx_hash))
+ menu.addAction(_("Details"), lambda: self.tx_details(tx_hash))
menu.addAction(_("Edit description"), lambda: self.tx_label_clicked(item,2))
menu.exec_(self.contacts_list.viewport().mapToGlobal(position))
- def tx_details(self, item, column):
- tx_hash = str(item.toolTip(0))
+ def tx_details(self, tx_hash):
tx = self.wallet.tx_history.get(tx_hash)
if tx['height']: