--- a/eric6/DebugClients/Python/ThreadExtension.py Fri Feb 14 19:52:37 2020 +0100 +++ b/eric6/DebugClients/Python/ThreadExtension.py Sat Feb 15 12:13:52 2020 +0100 @@ -406,9 +406,26 @@ super(QThreadWrapper, self).__init__(*args, **kwargs) + class QRunnableWrapper(module.QRunnable): + """ + Wrapper class for *.QRunnable. + """ + def __init__(self, *args, **kwargs): + """ + Constructor + """ + # Overwrite the provided run method with our own, to + # intercept the thread creation by Qt + self.run = lambda s=self, run=self.run: ( + _bootstrapQThread(s, run)) + + super(QRunnableWrapper, self).__init__(*args, **kwargs) + module.QThread = QThreadWrapper - - # TODO: add support for QRunnable + module.QRunnable = QRunnableWrapper + + self.enableImportHooks = True + return module # # eflag: noqa = M702