Split in two the options
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
This commit is contained in:
@ -41,7 +41,6 @@
|
||||
#include <QUuid>
|
||||
#include <memory>
|
||||
|
||||
#include "Application.h"
|
||||
#include "tasks/Task.h"
|
||||
|
||||
class ConcurrentTask : public Task {
|
||||
@ -49,11 +48,12 @@ class ConcurrentTask : public Task {
|
||||
public:
|
||||
using Ptr = shared_qobject_ptr<ConcurrentTask>;
|
||||
|
||||
explicit ConcurrentTask(QObject* parent = nullptr,
|
||||
QString task_name = "",
|
||||
int max_concurrent = APPLICATION->settings()->get("NumberOfConcurrentTasks").toInt());
|
||||
explicit ConcurrentTask(QObject* parent = nullptr, QString task_name = "", int max_concurrent = 6);
|
||||
~ConcurrentTask() override;
|
||||
|
||||
// safe to call before starting the task
|
||||
void setMaxConcurrent(int max_concurrent) { m_total_max_size = max_concurrent; }
|
||||
|
||||
bool canAbort() const override { return true; }
|
||||
|
||||
inline auto isMultiStep() const -> bool override { return totalSize() > 1; };
|
||||
|
Reference in New Issue
Block a user