1
0

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:
SomberNight
2020-04-01 18:42:06 +02:00
parent 276631fab7
commit e6d43b60fa
8 changed files with 40 additions and 13 deletions

View File

@@ -556,6 +556,8 @@ class DeviceMgr(ThreadJob):
keystore: 'Hardware_KeyStore', devices: List['Device'] = None) -> 'DeviceInfo':
'''Ask the user to select a device to use if there is more than one,
and return the DeviceInfo for the device.'''
# ideally this should not be called from the GUI thread...
# assert handler.get_gui_thread() != threading.current_thread(), 'must not be called from GUI thread'
while True:
infos = self.unpaired_device_infos(handler, plugin, devices)
if infos: