Moved Paths helper functions to service class

This commit is contained in:
Nav
2022-12-26 21:47:09 +00:00
parent 4c25c85c36
commit 8fa7e82c56
36 changed files with 131 additions and 125 deletions

View File

@@ -4,7 +4,7 @@
#include <QDir>
#include <QJsonDocument>
#include "src/Helpers/Paths.hpp"
#include "src/Services/PathService.hpp"
#include "src/Helpers/EnumToStringMappings.hpp"
#include "src/Logger/Logger.hpp"
@@ -83,7 +83,7 @@ namespace Bloom
std::move(this->excludedRegions)
);
const auto snapshotDirPath = QString::fromStdString(Paths::projectSettingsDirPath())
const auto snapshotDirPath = QString::fromStdString(Services::PathService::projectSettingsDirPath())
+ "/memory_snapshots/" + EnumToStringMappings::targetMemoryTypes.at(snapshot.memoryType);
QDir().mkpath(snapshotDirPath);

View File

@@ -5,7 +5,7 @@
#include <QStringList>
#include <QJsonDocument>
#include "src/Helpers/Paths.hpp"
#include "src/Services/PathService.hpp"
#include "src/Helpers/EnumToStringMappings.hpp"
#include "src/Exceptions/Exception.hpp"
#include "src/Logger/Logger.hpp"
@@ -23,7 +23,7 @@ namespace Bloom
}
std::vector<MemorySnapshot> RetrieveMemorySnapshots::getSnapshots(Targets::TargetMemoryType memoryType) {
auto snapshotDir = QDir(QString::fromStdString(Paths::projectSettingsDirPath())
auto snapshotDir = QDir(QString::fromStdString(Services::PathService::projectSettingsDirPath())
+ "/memory_snapshots/" + EnumToStringMappings::targetMemoryTypes.at(memoryType));
if (!snapshotDir.exists()) {