Changeset View
Changeset View
Standalone View
Standalone View
kcms/touchpad/src/touchpadbackend.h
Show All 19 Lines | |||||
20 | #ifndef TOUCHPADBACKEND_H | 20 | #ifndef TOUCHPADBACKEND_H | ||
21 | #define TOUCHPADBACKEND_H | 21 | #define TOUCHPADBACKEND_H | ||
22 | 22 | | |||
23 | #include <QObject> | 23 | #include <QObject> | ||
24 | #include <QVector> | 24 | #include <QVector> | ||
25 | #include <QVariantHash> | 25 | #include <QVariantHash> | ||
26 | 26 | | |||
27 | enum class TouchpadInputBackendMode { | 27 | enum class TouchpadInputBackendMode { | ||
28 | WaylandLibinput = 0, | 28 | Unset = 0, | ||
29 | XLibinput = 1, | 29 | WaylandLibinput = 1, | ||
30 | XSynaptics = 2 | 30 | XLibinput = 2, | ||
31 | XSynaptics = 3 | ||||
31 | }; | 32 | }; | ||
32 | 33 | | |||
33 | class Q_DECL_EXPORT TouchpadBackend : public QObject | 34 | class Q_DECL_EXPORT TouchpadBackend : public QObject | ||
34 | { | 35 | { | ||
35 | Q_OBJECT | 36 | Q_OBJECT | ||
36 | 37 | | |||
37 | protected: | 38 | protected: | ||
38 | explicit TouchpadBackend(QObject *parent) : QObject(parent) {} | 39 | explicit TouchpadBackend(QObject *parent) : QObject(parent), m_mode(TouchpadInputBackendMode::Unset) {} | ||
39 | void setMode(TouchpadInputBackendMode mode); | 40 | void setMode(TouchpadInputBackendMode mode); | ||
40 | 41 | | |||
41 | public: | 42 | public: | ||
42 | static TouchpadBackend *implementation(); | 43 | static TouchpadBackend *implementation(); | ||
43 | 44 | | |||
44 | TouchpadInputBackendMode getMode() const {return m_mode;} | 45 | TouchpadInputBackendMode getMode() const {return m_mode;} | ||
45 | 46 | | |||
46 | virtual bool applyConfig(const QVariantHash &) {return false;} | 47 | virtual bool applyConfig(const QVariantHash &) {return false;} | ||
▲ Show 20 Lines • Show All 42 Lines • Show Last 20 Lines |