Implement workaround for PySide bug
authorEd Page <eopage@byu.net>
Fri, 8 Apr 2011 23:26:20 +0000 (18:26 -0500)
committerEd Page <eopage@byu.net>
Tue, 19 Apr 2011 23:49:32 +0000 (18:49 -0500)
src/util/qore_utils.py

index 7780418..153558d 100644 (file)
@@ -34,8 +34,11 @@ class _WorkerThread(QtCore.QObject):
                self._taskComplete.connect(self._futureThread._on_task_complete)
 
        @qt_compat.Slot(object)
-       @misc.log_exception(_moduleLogger)
        def _on_task_added(self, task):
+               self.__on_task_added(task)
+
+       @misc.log_exception(_moduleLogger)
+       def __on_task_added(self, task):
                if not self._futureThread._isRunning:
                        _moduleLogger.error("Dropping task")
 
@@ -78,8 +81,11 @@ class FutureThread(QtCore.QObject):
                self._addTask.emit(task)
 
        @qt_compat.Slot(object)
-       @misc.log_exception(_moduleLogger)
        def _on_task_complete(self, taskResult):
+               self.__on_task_complete(taskResult)
+
+       @misc.log_exception(_moduleLogger)
+       def __on_task_complete(self, taskResult):
                on_success, on_error, isError, result = taskResult
                if not self._isRunning:
                        if isError: