Fix set process

This commit is contained in:
luiscuenca 2019-07-09 16:34:32 -07:00
parent ec63684866
commit 25c4ad76be
No known key found for this signature in database
GPG key ID: 2387ECD129A6961D

View file

@ -518,6 +518,7 @@ BOOL LauncherManager::extractApplication() {
std::function<void(float)> onProgress = [&](float progress) {
updateProgress(ProcessType::UnzipApplication, progress);
};
_currentProcess = ProcessType::UnzipApplication;
BOOL success = LauncherUtils::unzipFileOnThread(ProcessType::UnzipApplication,
LauncherUtils::cStringToStd(_applicationZipPath),
LauncherUtils::cStringToStd(installPath),
@ -578,6 +579,7 @@ BOOL LauncherManager::installContent() {
std::function<void(float)> onProgress = [&](float progress) {
updateProgress(ProcessType::UnzipContent, progress);
};
_currentProcess = ProcessType::UnzipContent;
BOOL success = LauncherUtils::unzipFileOnThread(ProcessType::UnzipContent, contentZipFile,
LauncherUtils::cStringToStd(contentPath), onInstallFinished, onProgress);
if (success) {
@ -636,6 +638,8 @@ void LauncherManager::onCancel() {
if (_currentProcess == ProcessType::UnzipApplication) {
_latestVersion = _T("");
_version = _T("");
createConfigJSON();
if (!createConfigJSON()) {
TRACE(_T("err"));
}
}
}