Browse Source

qt: fix macOS workaround introducing race

master
Sander van Grieken 2 years ago
parent
commit
17147732fb
No known key found for this signature in database
GPG Key ID: 9BCF8209EA402EBA
  1. 15
      electrum/gui/qt/wizard/wizard.py

15
electrum/gui/qt/wizard/wizard.py

@ -112,14 +112,6 @@ class QEAbstractWizard(QDialog, MessageBoxMixin):
QTimer.singleShot(40, self.strt)
# TODO: re-test if needed on macOS
self.refresh_gui() # Need for QT on MacOSX. Lame.
def refresh_gui(self):
# For some reason, to refresh the GUI this needs to be called twice
self.app.processEvents()
self.app.processEvents()
def sizeHint(self) -> QSize:
return QSize(600, 400)
@ -129,6 +121,13 @@ class QEAbstractWizard(QDialog, MessageBoxMixin):
else:
viewstate = self.start_wizard()
self.load_next_component(viewstate.view, viewstate.wizard_data, viewstate.params)
# TODO: re-test if needed on macOS
self.refresh_gui() # Need for QT on MacOSX. Lame.
def refresh_gui(self):
# For some reason, to refresh the GUI this needs to be called twice
self.app.processEvents()
self.app.processEvents()
def load_next_component(self, view, wdata=None, params=None):
if wdata is None:

Loading…
Cancel
Save