diff --git a/gui/qt/installwizard.py b/gui/qt/installwizard.py index db5dc34b..b1581c77 100644 --- a/gui/qt/installwizard.py +++ b/gui/qt/installwizard.py @@ -175,9 +175,8 @@ class InstallWizard(WindowModalDialog, WizardBase): return sanitized_seed() def show_seed(self, seed): - title = _("Your wallet generation seed is:") slayout = SeedWarningLayout(seed) - self.set_main_layout(slayout.layout(), title) + self.set_main_layout(slayout.layout()) def verify_seed(self, seed, is_valid=None): while True: diff --git a/gui/qt/main_window.py b/gui/qt/main_window.py index 7aaa3d08..e8cb1614 100644 --- a/gui/qt/main_window.py +++ b/gui/qt/main_window.py @@ -1830,7 +1830,7 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, PrintError): self.set_send_button_text() def change_password_dialog(self): - from password_dialog import PasswordDialog + from password_dialog import PasswordDialog, PW_CHANGE if self.wallet and self.wallet.is_watching_only(): self.show_error(_('This is a watching-only wallet')) @@ -1840,7 +1840,7 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, PrintError): 'password. To disable wallet encryption, enter an empty new ' 'password.') if self.wallet.use_encryption else _('Your wallet keys are not encrypted')) - d = PasswordDialog(self, self.wallet, msg, PasswordDialog.PW_CHANGE) + d = PasswordDialog(self, self.wallet, msg, PW_CHANGE) ok, password, new_password = d.run() if not ok: return diff --git a/gui/qt/network_dialog.py b/gui/qt/network_dialog.py index 6a3aa584..e5614d5c 100644 --- a/gui/qt/network_dialog.py +++ b/gui/qt/network_dialog.py @@ -34,7 +34,7 @@ class NetworkDialog(WindowModalDialog): self.setMinimumSize(375, 20) self.nlayout = NetworkChoiceLayout(network, config) vbox = QVBoxLayout(self) - vbox.addLayout(nlayout.layout()) + vbox.addLayout(self.nlayout.layout()) vbox.addLayout(Buttons(CancelButton(self), OkButton(self))) def do_exec(self): diff --git a/gui/qt/password_dialog.py b/gui/qt/password_dialog.py index 7e90656c..e5309ed3 100644 --- a/gui/qt/password_dialog.py +++ b/gui/qt/password_dialog.py @@ -93,7 +93,7 @@ class PasswordLayout(object): lockfile = ":icons/lock.png" else: lockfile = ":icons/unlock.png" - logo.setPixmap(QPixmap(lockfile).scaledToWidth(36)) + logo.setPixmap(QPixmap(lockfile).scaledToWidth(36)) grid.addWidget(QLabel(msgs[0]), 1, 0) grid.addWidget(self.new_pw, 1, 1) @@ -145,10 +145,10 @@ class PasswordLayout(object): class PasswordDialog(WindowModalDialog): def __init__(self, parent, wallet, msg, kind): - WindowModalDialog.__init__(self) + WindowModalDialog.__init__(self, parent) OK_button = OkButton(self) self.playout = PasswordLayout(wallet, msg, kind, OK_button) - self.setTitle(slef.playout.title()) + self.setWindowTitle(self.playout.title()) vbox = QVBoxLayout(self) vbox.addLayout(self.playout.layout()) vbox.addStretch(1) diff --git a/gui/qt/seed_dialog.py b/gui/qt/seed_dialog.py index 9e17cacf..1270954b 100644 --- a/gui/qt/seed_dialog.py +++ b/gui/qt/seed_dialog.py @@ -36,7 +36,7 @@ class SeedDialog(WindowModalDialog): WindowModalDialog.__init__(self, parent, ('Electrum - ' + _('Seed'))) self.setMinimumWidth(400) vbox = QVBoxLayout(self) - vbox.addLayout(SeedDisplayLayout(seed)) + vbox.addLayout(SeedWarningLayout(seed).layout()) if imported_keys: warning = ("" + _("WARNING") + ": " + _("Your wallet contains imported keys. These keys " @@ -86,6 +86,8 @@ class SeedDisplayLayout(SeedLayoutBase): class SeedWarningLayout(SeedLayoutBase): def __init__(self, seed, title=None): + if title is None: + title = _("Your wallet generation seed is:") msg = ''.join([ "

", _("Please save these %d words on paper (order is important). "),