mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-08-31 09:21:39 +00:00
bitbox02: rm some dead code
This commit is contained in:
parent
15102855c1
commit
0268b63fcb
4 changed files with 4 additions and 47 deletions
|
@ -131,8 +131,9 @@ class BitBox02Client(HardwareClientBase):
|
|||
self.config.set_key("bitbox02", bitbox02_config)
|
||||
|
||||
def attestation_warning() -> None:
|
||||
self.handler.attestation_failed_warning(
|
||||
"The BitBox02 attestation failed.\nTry reconnecting the BitBox02.\nWarning: The device might not be genuine, if the\n problem persists please contact Shift support."
|
||||
self.handler.show_error(
|
||||
"The BitBox02 attestation failed.\nTry reconnecting the BitBox02.\nWarning: The device might not be genuine, if the\n problem persists please contact Shift support.",
|
||||
blocking=True
|
||||
)
|
||||
|
||||
class NoiseConfig(bitbox_api_protocol.BitBoxNoiseConfig):
|
||||
|
|
|
@ -89,11 +89,9 @@ class Plugin(BitBox02Plugin, QtPluginBase):
|
|||
|
||||
|
||||
class BitBox02_Handler(QtHandlerBase):
|
||||
setup_signal = pyqtSignal()
|
||||
|
||||
def __init__(self, win):
|
||||
super(BitBox02_Handler, self).__init__(win, "BitBox02")
|
||||
self.setup_signal.connect(self.setup_dialog)
|
||||
|
||||
def message_dialog(self, msg):
|
||||
self.clear_dialog()
|
||||
|
@ -105,24 +103,6 @@ class BitBox02_Handler(QtHandlerBase):
|
|||
vbox.addWidget(l)
|
||||
dialog.show()
|
||||
|
||||
def attestation_failed_warning(self, msg):
|
||||
self.clear_dialog()
|
||||
self.dialog = dialog = WindowModalDialog(None, "BitBox02 Attestation Failed")
|
||||
l = QLabel(msg)
|
||||
vbox = QVBoxLayout(dialog)
|
||||
vbox.addWidget(l)
|
||||
okButton = OkButton(dialog)
|
||||
vbox.addWidget(okButton)
|
||||
dialog.setLayout(vbox)
|
||||
dialog.exec_()
|
||||
return
|
||||
|
||||
def get_setup(self):
|
||||
self.done.clear()
|
||||
self.setup_signal.emit()
|
||||
self.done.wait()
|
||||
return
|
||||
|
||||
def name_multisig_account(self):
|
||||
return QMetaObject.invokeMethod(
|
||||
self,
|
||||
|
@ -157,7 +137,3 @@ class BitBox02_Handler(QtHandlerBase):
|
|||
dialog.setLayout(vbox)
|
||||
dialog.exec_()
|
||||
return name.text().strip()
|
||||
|
||||
def setup_dialog(self):
|
||||
self.show_error(_("Please initialize your BitBox02 while connected."))
|
||||
return
|
||||
|
|
|
@ -28,12 +28,6 @@ class ColdcardCmdLineHandler(CmdLineHandler):
|
|||
def stop(self):
|
||||
pass
|
||||
|
||||
def show_message(self, msg, on_cancel=None):
|
||||
print_stderr(msg)
|
||||
|
||||
def show_error(self, msg, blocking=False):
|
||||
print_stderr(msg)
|
||||
|
||||
def update_status(self, b):
|
||||
_logger.info(f'hw device status {b}')
|
||||
|
||||
|
|
|
@ -77,15 +77,10 @@ class Plugin(ColdcardPlugin, QtPluginBase):
|
|||
|
||||
|
||||
class Coldcard_Handler(QtHandlerBase):
|
||||
setup_signal = pyqtSignal()
|
||||
#auth_signal = pyqtSignal(object)
|
||||
|
||||
def __init__(self, win):
|
||||
super(Coldcard_Handler, self).__init__(win, 'Coldcard')
|
||||
self.setup_signal.connect(self.setup_dialog)
|
||||
#self.auth_signal.connect(self.auth_dialog)
|
||||
|
||||
|
||||
def message_dialog(self, msg):
|
||||
self.clear_dialog()
|
||||
self.dialog = dialog = WindowModalDialog(self.top_level_window(), _("Coldcard Status"))
|
||||
|
@ -93,16 +88,7 @@ class Coldcard_Handler(QtHandlerBase):
|
|||
vbox = QVBoxLayout(dialog)
|
||||
vbox.addWidget(l)
|
||||
dialog.show()
|
||||
|
||||
def get_setup(self):
|
||||
self.done.clear()
|
||||
self.setup_signal.emit()
|
||||
self.done.wait()
|
||||
return
|
||||
|
||||
def setup_dialog(self):
|
||||
self.show_error(_('Please initialize your Coldcard while disconnected.'))
|
||||
return
|
||||
|
||||
|
||||
class CKCCSettingsDialog(WindowModalDialog):
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue