diff options
author | Petr Mrázek <peterix@gmail.com> | 2021-12-31 05:27:59 +0100 |
---|---|---|
committer | Petr Mrázek <peterix@gmail.com> | 2021-12-31 05:27:59 +0100 |
commit | 9579231ccc36d9d32f4d5571ced91e8fe7851643 (patch) | |
tree | d91a8a010d6159d6a9b058b8383fc1da0d765bb7 /launcher/ui/pages/modplatform/atlauncher | |
parent | 9cc168c5261c6cd0523287e995da58beee8f5096 (diff) | |
download | PrismLauncher-9579231ccc36d9d32f4d5571ced91e8fe7851643.tar.gz PrismLauncher-9579231ccc36d9d32f4d5571ced91e8fe7851643.tar.bz2 PrismLauncher-9579231ccc36d9d32f4d5571ced91e8fe7851643.zip |
NOISSUE fix build and change how NetJob is used
Feed it network upfront...
Diffstat (limited to 'launcher/ui/pages/modplatform/atlauncher')
-rw-r--r-- | launcher/ui/pages/modplatform/atlauncher/AtlListModel.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/launcher/ui/pages/modplatform/atlauncher/AtlListModel.cpp b/launcher/ui/pages/modplatform/atlauncher/AtlListModel.cpp index 82e383ca..ef9a9268 100644 --- a/launcher/ui/pages/modplatform/atlauncher/AtlListModel.cpp +++ b/launcher/ui/pages/modplatform/atlauncher/AtlListModel.cpp @@ -86,11 +86,11 @@ void ListModel::request() modpacks.clear(); endResetModel(); - auto *netJob = new NetJob("Atl::Request"); + auto *netJob = new NetJob("Atl::Request", APPLICATION->network()); auto url = QString(BuildConfig.ATL_DOWNLOAD_SERVER_URL + "launcher/json/packsnew.json"); netJob->addNetAction(Net::Download::makeByteArray(QUrl(url), &response)); jobPtr = netJob; - jobPtr->start(APPLICATION->network()); + jobPtr->start(); QObject::connect(netJob, &NetJob::succeeded, this, &ListModel::requestFinished); QObject::connect(netJob, &NetJob::failed, this, &ListModel::requestFailed); @@ -183,7 +183,7 @@ void ListModel::requestLogo(QString file, QString url) } MetaEntryPtr entry = APPLICATION->metacache()->resolveEntry("ATLauncherPacks", QString("logos/%1").arg(file.section(".", 0, 0))); - NetJob *job = new NetJob(QString("ATLauncher Icon Download %1").arg(file)); + NetJob *job = new NetJob(QString("ATLauncher Icon Download %1").arg(file), APPLICATION->network()); job->addNetAction(Net::Download::makeCached(QUrl(url), entry)); auto fullPath = entry->getFullPath(); @@ -201,7 +201,7 @@ void ListModel::requestLogo(QString file, QString url) emit logoFailed(file); }); - job->start(APPLICATION->network()); + job->start(); m_loadingLogos.append(file); } |