1
0
Fork 0
mirror of https://github.com/borgbase/vorta synced 2024-12-22 07:43:09 +00:00

Fixes #2120 (ammended)

This commit is contained in:
mycir 2024-11-22 10:40:49 +00:00
parent 84fbf14dde
commit 420be650c0

View file

@ -58,9 +58,13 @@ def __init__(self, decorator_instance, wrapped_instance):
self.wrapped_instance = wrapped_instance
def __call__(self, *args, **kwargs):
global runner_thread
runner_thread = AsyncRunner.Runner(self.decorator_instance, self.wrapped_instance, *args, **kwargs)
runner_thread.start()
self.runner = AsyncRunner.Runner(self.decorator_instance, self.wrapped_instance, *args, **kwargs)
self.runner.finished.connect(self.runner_finished)
self.runner.start()
def runner_finished(self):
self.runner.wait(100)
self.runner = None
class Runner(QtCore.QThread):
def __init__(self, decorator_instance, wrapped_instance, *args, **kwargs):
@ -72,8 +76,11 @@ def __init__(self, decorator_instance, wrapped_instance, *args, **kwargs):
def run(self):
self.decorator_instance(self.wrapped_instance, *self.args, **self.kwargs)
<<<<<<< HEAD
self.terminate()
self.wait()
=======
>>>>>>> d7d1488 (Fixes #2120 (ammended))
class FilePathInfoAsync(QThread):