mirror of
https://github.com/YACReader/yacreader
synced 2025-07-21 06:24:39 -04:00
moved settings files from local dir to standar paths
added YACReaderLibraries class, libraries are now identified by id
This commit is contained in:
13
common/yacreader_global.cpp
Normal file
13
common/yacreader_global.cpp
Normal file
@ -0,0 +1,13 @@
|
||||
#include "yacreader_global.h"
|
||||
|
||||
using namespace YACReader;
|
||||
|
||||
QString YACReader::getSettingsPath()
|
||||
{
|
||||
#if QT_VERSION >= 0x050000
|
||||
return QStandardPaths::writableLocation(QStandardPaths::ConfigLocation);
|
||||
#else
|
||||
return QDesktopServices::storageLocation(QDesktopServices::DataLocation);
|
||||
#endif
|
||||
|
||||
}
|
@ -1,6 +1,13 @@
|
||||
#ifndef __YACREADER_GLOBAL_H
|
||||
#define __YACREADER_GLOBAL_H
|
||||
|
||||
#if QT_VERSION >= 0x050000
|
||||
#include <QStandardPaths>
|
||||
#else
|
||||
#include <QDesktopServices>
|
||||
#endif
|
||||
|
||||
|
||||
#define VERSION "6.5.3"
|
||||
|
||||
#define PATH "PATH"
|
||||
@ -53,6 +60,8 @@
|
||||
|
||||
#define YACREADERLIBRARY_GUID "ea343ff3-2005-4865-b212-7fa7c43999b8"
|
||||
|
||||
#define LIBRARIES "LIBRARIES"
|
||||
|
||||
namespace YACReader
|
||||
{
|
||||
|
||||
@ -79,6 +88,8 @@ namespace YACReader
|
||||
Opened = 2
|
||||
};
|
||||
|
||||
QString getSettingsPath();
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user