Browse Source

Merge pull request #1327 from romanz/master

transaction_dialog: allow plugins manipulate transaction sharing buttons
283
ThomasV 10 years ago
parent
commit
dbdbdc8792
  1. 5
      gui/qt/transaction_dialog.py
  2. 2
      plugins/audio_modem.py

5
gui/qt/transaction_dialog.py

@ -99,10 +99,13 @@ class TxDialog(QWidget):
# Action buttons
self.buttons = [self.sign_button, self.broadcast_button, self.cancel_button]
# Transaction sharing buttons
self.sharing_buttons = [self.copy_button, self.qr_button, self.save_button]
run_hook('transaction_dialog', self)
hbox = QHBoxLayout()
hbox.addLayout(Buttons(self.copy_button, self.qr_button, self.save_button))
hbox.addLayout(Buttons(*self.sharing_buttons))
hbox.addStretch(1)
hbox.addLayout(Buttons(*self.buttons))
vbox.addLayout(hbox)

2
plugins/audio_modem.py

@ -78,7 +78,7 @@ class Plugin(BasePlugin):
self.sender = self._send(parent=dialog, blob=blob)
self.sender.start()
b.clicked.connect(handler)
dialog.buttons.insert(0, b)
dialog.sharing_buttons.insert(-1, b)
@hook
def scan_text_edit(self, parent):

Loading…
Cancel
Save