summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/preferences/abstractpreferenceswidget.h
diff options
context:
space:
mode:
Diffstat (limited to 'desktop-widgets/preferences/abstractpreferenceswidget.h')
-rw-r--r--desktop-widgets/preferences/abstractpreferenceswidget.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/desktop-widgets/preferences/abstractpreferenceswidget.h b/desktop-widgets/preferences/abstractpreferenceswidget.h
new file mode 100644
index 000000000..2f607c4c9
--- /dev/null
+++ b/desktop-widgets/preferences/abstractpreferenceswidget.h
@@ -0,0 +1,27 @@
+#ifndef ABSTRACTPREFERENCESWIDGET_H
+#define ABSTRACTPREFERENCESWIDGET_H
+
+#include <QIcon>
+#include <QWidget>
+
+class AbstractPreferencesWidget : public QWidget {
+ Q_OBJECT
+public:
+ AbstractPreferencesWidget(const QString& name, const QIcon& icon, float positionHeight);
+ QIcon icon() const;
+ QString name() const;
+ float positionHeight() const;
+
+ /* gets the values from the preferences and should set the correct values in
+ * the interface */
+ virtual void refreshSettings() = 0;
+
+ /* gets the values from the interface and set in the preferences object. */
+ virtual void syncSettings() = 0;
+
+private:
+ QIcon _icon;
+ QString _name;
+ float _positionHeight;
+};
+#endif \ No newline at end of file