qt hww show_settings_dialog: don't scan devices in GUI thread
Just makes sense in general. Also, previously, the GUI would freeze if right after startup the user clicked the hww status bar icon (especially with multiple hww connected).
This commit is contained in:
@@ -182,9 +182,13 @@ class QtPlugin(QtPluginBase):
|
||||
menu.addAction(_("Show on {}").format(device_name), show_address)
|
||||
|
||||
def show_settings_dialog(self, window, keystore):
|
||||
device_id = self.choose_device(window, keystore)
|
||||
if device_id:
|
||||
SettingsDialog(window, self, keystore, device_id).exec_()
|
||||
def connect():
|
||||
device_id = self.choose_device(window, keystore)
|
||||
return device_id
|
||||
def show_dialog(device_id):
|
||||
if device_id:
|
||||
SettingsDialog(window, self, keystore, device_id).exec_()
|
||||
keystore.thread.add(connect, on_success=show_dialog)
|
||||
|
||||
def request_trezor_init_settings(self, wizard, method, device_id):
|
||||
vbox = QVBoxLayout()
|
||||
|
||||
Reference in New Issue
Block a user