moved settings files from local dir to standar paths

added YACReaderLibraries class, libraries are now identified by id
This commit is contained in:
Luis Ángel San Martín
2013-11-15 00:07:42 +01:00
parent 5394a603e3
commit e51480469f
25 changed files with 318 additions and 168 deletions

View 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
}

View File

@ -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