ukui-search/ukui-search-service-dir-man.../dirwatcher/config.h

32 lines
711 B
C
Raw Normal View History

#ifndef CONFIG_H
#define CONFIG_H
#include <QString>
#include <QSettings>
#include <QVector>
#include "search-dir.h"
class Config
{
public:
static Config *self();
void addDir(const SearchDir& dir);
QStringList removeDir(const SearchDir& dir);
/**
* @brief
* @return
*/
bool isCompatibilityMode();
QVector<SearchDir> searchDirObjects() const;
QStringList searchDirs() const;
QStringList blackDirs() const;
QStringList globalBlackList() const;
private:
Config();
QSettings *m_settings = nullptr;
bool m_compatibilityMode = false;
QVector<SearchDir> m_searchDirs;
};
#endif // CONFIG_H