build: split user and data folder, moving user data to Application Support on Mac

This commit is contained in:
Eberhard Graether
2016-02-16 16:44:42 +01:00
parent 89b8d51ab8
commit 86cf1ee62d
51 changed files with 176 additions and 1809 deletions
-2
View File
@@ -3,8 +3,6 @@
#include <string>
// #include "src\lib_gui\includes.h"
#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
#define NOMINMAX
+28
View File
@@ -0,0 +1,28 @@
#include "utility/UserPaths.h"
std::string UserPaths::s_userDataPath = "user/";
std::string UserPaths::getUserDataPath()
{
return s_userDataPath;
}
void UserPaths::setUserDataPath(const std::string& path)
{
s_userDataPath = path;
}
std::string UserPaths::getAppSettingsPath()
{
return getUserDataPath() + "ApplicationSettings.xml";
}
std::string UserPaths::getWindowSettingsPath()
{
return getUserDataPath() + "window_settings.ini";
}
std::string UserPaths::getLogPath()
{
return getUserDataPath() + "log/";
}
+20
View File
@@ -0,0 +1,20 @@
#ifndef USER_PATHS_H
#define USER_PATHS_H
#include <string>
class UserPaths
{
public:
static std::string getUserDataPath();
static void setUserDataPath(const std::string& path);
static std::string getAppSettingsPath();
static std::string getWindowSettingsPath();
static std::string getLogPath();
private:
static std::string s_userDataPath;
};
#endif // USER_PATHS_H