| 40 | } |
| 41 | } |
| 42 | bool ProgressWidget::exec(std::shared_ptr<Task> task) |
| 43 | { |
| 44 | QEventLoop loop; |
| 45 | connect(task.get(), &Task::finished, &loop, &QEventLoop::quit); |
| 46 | start(task); |
| 47 | if (task->isRunning()) |
| 48 | { |
| 49 | loop.exec(); |
| 50 | } |
| 51 | return task->wasSuccessful(); |
| 52 | } |
| 53 | |
| 54 | void ProgressWidget::handleTaskFinish() |
| 55 | { |
no test coverage detected