Changeset View
Changeset View
Standalone View
Standalone View
src/edid.h
Show All 24 Lines | |||||
25 | 25 | | |||
26 | #include <QtCore/QObject> | 26 | #include <QtCore/QObject> | ||
27 | #include <QtCore/QtGlobal> | 27 | #include <QtCore/QtGlobal> | ||
28 | #include <QtGui/QQuaternion> | 28 | #include <QtGui/QQuaternion> | ||
29 | 29 | | |||
30 | namespace KScreen | 30 | namespace KScreen | ||
31 | { | 31 | { | ||
32 | 32 | | |||
33 | class ConfigSerializer; | ||||
34 | | ||||
33 | class KSCREEN_EXPORT Edid: public QObject | 35 | class KSCREEN_EXPORT Edid: public QObject | ||
34 | { | 36 | { | ||
35 | Q_OBJECT | 37 | Q_OBJECT | ||
36 | 38 | | |||
37 | Q_PROPERTY(QString deviceId READ deviceId CONSTANT) | 39 | Q_PROPERTY(QString deviceId READ deviceId CONSTANT) | ||
38 | Q_PROPERTY(QString name READ name CONSTANT) | 40 | Q_PROPERTY(QString name READ name CONSTANT) | ||
39 | Q_PROPERTY(QString vendor READ vendor CONSTANT) | 41 | Q_PROPERTY(QString vendor READ vendor CONSTANT) | ||
40 | Q_PROPERTY(QString serial READ serial CONSTANT) | 42 | Q_PROPERTY(QString serial READ serial CONSTANT) | ||
41 | Q_PROPERTY(QString eisaId READ eisaId CONSTANT) | 43 | Q_PROPERTY(QString eisaId READ eisaId CONSTANT) | ||
42 | Q_PROPERTY(QString hash READ hash CONSTANT) | 44 | Q_PROPERTY(QString hash READ hash CONSTANT) | ||
43 | Q_PROPERTY(uint width READ width CONSTANT) | 45 | Q_PROPERTY(uint width READ width CONSTANT) | ||
44 | Q_PROPERTY(uint height READ height CONSTANT) | 46 | Q_PROPERTY(uint height READ height CONSTANT) | ||
45 | Q_PROPERTY(qreal gamma READ gamma CONSTANT) | 47 | Q_PROPERTY(qreal gamma READ gamma CONSTANT) | ||
46 | Q_PROPERTY(QQuaternion red READ red CONSTANT) | 48 | Q_PROPERTY(QQuaternion red READ red CONSTANT) | ||
47 | Q_PROPERTY(QQuaternion green READ green CONSTANT) | 49 | Q_PROPERTY(QQuaternion green READ green CONSTANT) | ||
48 | Q_PROPERTY(QQuaternion blue READ blue CONSTANT) | 50 | Q_PROPERTY(QQuaternion blue READ blue CONSTANT) | ||
49 | Q_PROPERTY(QQuaternion white READ white CONSTANT) | 51 | Q_PROPERTY(QQuaternion white READ white CONSTANT) | ||
50 | 52 | | |||
51 | public: | 53 | public: | ||
54 | class Private; | ||||
55 | | ||||
52 | explicit Edid(); | 56 | explicit Edid(); | ||
53 | explicit Edid(const QByteArray &data, QObject *parent = nullptr); | 57 | explicit Edid(const QByteArray &data, QObject *parent = nullptr); | ||
58 | explicit Edid(Private *dd); | ||||
54 | virtual ~Edid(); | 59 | virtual ~Edid(); | ||
55 | 60 | | |||
56 | Edid* clone() const; | 61 | Edid* clone() const; | ||
57 | 62 | | |||
58 | bool isValid() const; | 63 | bool isValid() const; | ||
59 | 64 | | |||
60 | QString deviceId(const QString &fallbackName = QString()) const; | 65 | QString deviceId(const QString &fallbackName = QString()) const; | ||
61 | QString name() const; | 66 | QString name() const; | ||
62 | QString vendor() const; | 67 | QString vendor() const; | ||
63 | QString serial() const; | 68 | QString serial() const; | ||
64 | QString eisaId() const; | 69 | QString eisaId() const; | ||
65 | QString hash() const; | 70 | QString hash() const; | ||
66 | QString pnpId() const; | 71 | QString pnpId() const; | ||
67 | uint width() const; | 72 | uint width() const; | ||
68 | uint height() const; | 73 | uint height() const; | ||
69 | qreal gamma() const; | 74 | qreal gamma() const; | ||
70 | QQuaternion red() const; | 75 | QQuaternion red() const; | ||
71 | QQuaternion green() const; | 76 | QQuaternion green() const; | ||
72 | QQuaternion blue() const; | 77 | QQuaternion blue() const; | ||
73 | QQuaternion white() const; | 78 | QQuaternion white() const; | ||
74 | 79 | | |||
75 | private: | 80 | private: | ||
76 | Q_DISABLE_COPY(Edid) | 81 | Q_DISABLE_COPY(Edid) | ||
77 | 82 | | |||
78 | class Private; | | |||
79 | Private * const d; | 83 | Private * const d; | ||
80 | | ||||
81 | Edid(Private *dd); | | |||
82 | }; | 84 | }; | ||
83 | 85 | | |||
84 | } | 86 | } | ||
85 | 87 | | |||
86 | Q_DECLARE_METATYPE(KScreen::Edid*) | 88 | Q_DECLARE_METATYPE(KScreen::Edid*) | ||
87 | 89 | | |||
88 | #endif // EDID_H | 90 | #endif // EDID_H |