first commit
This commit is contained in:
67
project/fm_viewer/rm_settings.h
Normal file
67
project/fm_viewer/rm_settings.h
Normal file
@@ -0,0 +1,67 @@
|
||||
#ifndef RM_SETTINGS_H
|
||||
#define RM_SETTINGS_H
|
||||
#include <QObject>
|
||||
class QSettings;
|
||||
class RMSettings : QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
#if (PLAYER_ONLY_LIBRARY_MODE)
|
||||
static RMSettings* RMSettings::_instance;
|
||||
static RMSettings* instance()
|
||||
{
|
||||
return _instance;
|
||||
}
|
||||
static void updateInstance(RMSettings* instance)
|
||||
{
|
||||
_instance = instance;
|
||||
}
|
||||
#else // PLAYER_ONLY_LIBRARY_MODE
|
||||
static RMSettings* instance()
|
||||
{
|
||||
static RMSettings * _instance = 0;
|
||||
if ( _instance == 0 ) {
|
||||
_instance = new RMSettings();
|
||||
}
|
||||
return _instance;
|
||||
}
|
||||
#endif // PLAYER_ONLY_LIBRARY_MODE
|
||||
explicit RMSettings(QObject *parent = 0);
|
||||
QSettings* settings;
|
||||
void load();
|
||||
|
||||
QString lastMoviePath();
|
||||
void setLastMoviePath(QString& path);
|
||||
|
||||
QString lastBackupPath();
|
||||
void setLastBackupPath(QString& path);
|
||||
|
||||
bool HWAccelOff();
|
||||
void setHWAccelOff(bool off);
|
||||
|
||||
int nullBitrate(); // 후방 제거 비트레이트 설정
|
||||
#if (SELECT_AUDIO_BACKEND)
|
||||
//bool XAudioOff();
|
||||
//void setXAudioOff(bool off);
|
||||
QString AudioDevice();
|
||||
void setAudioDevice(QString device);
|
||||
#endif
|
||||
|
||||
#if (LIVE_LANGUAGE_CHANGE)
|
||||
int language();
|
||||
void setLanguage(int language);
|
||||
bool autoLanguage();
|
||||
void setAutoLanguage(bool bAuto);
|
||||
#endif
|
||||
|
||||
#if (RM_TESTING)
|
||||
QString lastScript();
|
||||
void setLastScript(QString& path);
|
||||
#endif
|
||||
|
||||
private:
|
||||
QString _loadString(const char* group,const char* item);
|
||||
void _setString(const char* group,const char* item, QString value);
|
||||
};
|
||||
|
||||
#endif // RM_SETTINGS_H
|
||||
Reference in New Issue
Block a user