1
0

Permit sweep of private keys for watch-only wallet

Fixes #1585
Warn user if watching-only.
Introduce new helper class WindowModalDialog and use it in a couple
of places.  This is better than process-modal dialogs for our
multi-window daemon setup.
This commit is contained in:
Neil Booth
2015-12-21 23:52:48 +09:00
parent d8c080b87d
commit 8598f9ef9c
2 changed files with 16 additions and 7 deletions

View File

@@ -192,6 +192,14 @@ class CancelButton(QPushButton):
QPushButton.__init__(self, label or _("Cancel"))
self.clicked.connect(dialog.reject)
class WindowModalDialog(QDialog):
'''Handy wrapper; window modal dialogs are better for our multi-window
daemon model as other wallet windows can still be accessed.'''
def __init__(self, parent, title=None):
QDialog.__init__(self, parent)
self.setWindowModality(Qt.WindowModal)
if title:
self.setWindowTitle(title)
def line_dialog(parent, title, label, ok_label, default=None):
dialog = QDialog(parent)