mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
3ee8c665df
This will be the central location for all of qTox managed directories.
36 lines
807 B
C++
36 lines
807 B
C++
#ifndef PATHS_H
|
|
#define PATHS_H
|
|
|
|
#include <QString>
|
|
#include <QStringList>
|
|
|
|
class Paths
|
|
{
|
|
public:
|
|
enum class Portable {
|
|
Auto, /** Auto detect if portable or non-portable */
|
|
Portable, /** Force portable mode */
|
|
NonPortable /** Force non-portable mode */
|
|
};
|
|
|
|
static Paths* makePaths(Portable mode = Portable::Auto);
|
|
|
|
bool isPortable() const;
|
|
QString getGlobalSettingsPath() const;
|
|
QString getProfilesDir() const;
|
|
QString getToxSaveDir() const;
|
|
QString getAvatarsDir() const;
|
|
QString getTransfersDir() const;
|
|
QStringList getThemeDirs() const;
|
|
QString getScreenshotsDir() const;
|
|
|
|
private:
|
|
Paths(const QString &basePath, bool portable);
|
|
|
|
private:
|
|
QString basePath{};
|
|
bool portable = false;
|
|
};
|
|
|
|
#endif // PATHS_H
|