electrum

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

commit ddc989c672231392c07ab26c5721ac8b9605407e
parent 68ca0b73b17aed22e69fd672dfb6d45b880a5a12
Author: ThomasV <thomasv@electrum.org>
Date:   Wed, 18 Oct 2017 16:11:30 +0200

fix #3062

Diffstat:
Mplugins/trustedcoin/qt.py | 11+++++------
1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/plugins/trustedcoin/qt.py b/plugins/trustedcoin/qt.py @@ -40,15 +40,14 @@ from electrum.plugins import hook from .trustedcoin import TrustedCoinPlugin, server -class QTOSSignalObject(QObject): - two_factor_tos_signal = pyqtSignal() +class TOS(QTextEdit): + tos_signal = pyqtSignal() class Plugin(TrustedCoinPlugin): def __init__(self, parent, config, name): super().__init__(parent, config, name) - self.tos_signal_obj = QTOSSignalObject() @hook def on_new_window(self, window): @@ -189,7 +188,7 @@ class Plugin(TrustedCoinPlugin): vbox = QVBoxLayout() vbox.addWidget(QLabel(_("Terms of Service"))) - tos_e = QTextEdit() + tos_e = TOS() tos_e.setReadOnly(True) vbox.addWidget(tos_e) @@ -204,7 +203,7 @@ class Plugin(TrustedCoinPlugin): def request_TOS(): tos = server.get_terms_of_service() self.TOS = tos - self.tos_signal_obj.two_factor_tos_signal.emit() + tos_e.tos_signal.emit() def on_result(): tos_e.setText(self.TOS) @@ -212,7 +211,7 @@ class Plugin(TrustedCoinPlugin): def set_enabled(): next_button.setEnabled(re.match(regexp,email_e.text()) is not None) - self.tos_signal_obj.two_factor_tos_signal.connect(on_result) + tos_e.tos_signal.connect(on_result) t = Thread(target=request_TOS) t.setDaemon(True) t.start()