pollymc/launcher/minecraft/update/FoldersTask.cpp
Sefa Eyeoglu a5fc640f2c
Merge pull request #298 from Scrumplex/fix-i18n
Fix translatable strings
2022-03-22 20:11:15 +01:00

22 lines
437 B
C++

#include "FoldersTask.h"
#include "minecraft/MinecraftInstance.h"
#include <QDir>
FoldersTask::FoldersTask(MinecraftInstance * inst)
:Task()
{
m_inst = inst;
}
void FoldersTask::executeTask()
{
// Make directories
QDir mcDir(m_inst->gameRoot());
if (!mcDir.exists() && !mcDir.mkpath("."))
{
emitFailed(tr("Failed to create folder for Minecraft binaries."));
return;
}
emitSucceeded();
}