made the number of concurrent tasks configurable

Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
This commit is contained in:
Trial97
2023-07-14 20:39:53 +03:00
parent 3becd4386b
commit cebb4dd17a
8 changed files with 38 additions and 6 deletions

View File

@ -33,7 +33,7 @@ EnsureMetadataTask::EnsureMetadataTask(Mod* mod, QDir dir, ModPlatform::Resource
EnsureMetadataTask::EnsureMetadataTask(QList<Mod*>& mods, QDir dir, ModPlatform::ResourceProvider prov)
: Task(nullptr), m_index_dir(dir), m_provider(prov), m_current_task(nullptr)
{
m_hashing_task.reset(new ConcurrentTask(this, "MakeHashesTask", 10));
m_hashing_task.reset(new ConcurrentTask(this, "MakeHashesTask"));
for (auto* mod : mods) {
auto hash_task = createNewHash(mod);
if (!hash_task)