abstract qt away from trezor
This commit is contained in:
@@ -125,7 +125,7 @@ class QtHandler(QtHandlerBase):
|
|||||||
self.done.wait()
|
self.done.wait()
|
||||||
data = self.matrix_dialog.data
|
data = self.matrix_dialog.data
|
||||||
if data == 'x':
|
if data == 'x':
|
||||||
self.close_matrix_dialog_signal.emit()
|
self.close_matrix_dialog()
|
||||||
return data
|
return data
|
||||||
|
|
||||||
def _close_matrix_dialog(self):
|
def _close_matrix_dialog(self):
|
||||||
@@ -133,6 +133,9 @@ class QtHandler(QtHandlerBase):
|
|||||||
self.matrix_dialog.accept()
|
self.matrix_dialog.accept()
|
||||||
self.matrix_dialog = None
|
self.matrix_dialog = None
|
||||||
|
|
||||||
|
def close_matrix_dialog(self):
|
||||||
|
self.close_matrix_dialog_signal.emit()
|
||||||
|
|
||||||
def pin_dialog(self, msg):
|
def pin_dialog(self, msg):
|
||||||
# Needed e.g. when resetting a device
|
# Needed e.g. when resetting a device
|
||||||
self.clear_dialog()
|
self.clear_dialog()
|
||||||
|
|||||||
@@ -250,7 +250,7 @@ class TrezorPlugin(HW_PluginBase):
|
|||||||
pin_protection, label, language,
|
pin_protection, label, language,
|
||||||
type=recovery_type_trezor)
|
type=recovery_type_trezor)
|
||||||
if recovery_type == RECOVERY_TYPE_MATRIX:
|
if recovery_type == RECOVERY_TYPE_MATRIX:
|
||||||
handler.close_matrix_dialog_signal.emit()
|
handler.close_matrix_dialog()
|
||||||
elif method == TIM_MNEMONIC:
|
elif method == TIM_MNEMONIC:
|
||||||
pin = pin_protection # It's the pin, not a boolean
|
pin = pin_protection # It's the pin, not a boolean
|
||||||
client.load_device_by_mnemonic(str(item), pin,
|
client.load_device_by_mnemonic(str(item), pin,
|
||||||
|
|||||||
Reference in New Issue
Block a user