1
0
forked from blue/squawk
squawk/ui/widgets/settings/settings.h
2022-01-21 22:02:50 +03:00

40 lines
660 B
C++

#ifndef SETTINGS_H
#define SETTINGS_H
#include <QWidget>
#include <QListWidgetItem>
#include <QScopedPointer>
#include <QSettings>
#include "shared/global.h"
namespace Ui
{
class Settings;
}
/**
* @todo write docs
*/
class Settings : public QWidget
{
Q_OBJECT
public:
Settings(QWidget* parent = nullptr);
~Settings();
public slots:
void apply();
void confirm();
protected slots:
void onCurrentPageChanged(QListWidgetItem* current);
void onVariableModified(const QString& key, const QVariant& value);
private:
QScopedPointer<Ui::Settings> m_ui;
std::map<QString, QVariant> modifiedSettings;
};
#endif // SETTINGS_H