Changeset View
Changeset View
Standalone View
Standalone View
plugins/platforms/virtual/virtual_output.h
Show All 14 Lines | |||||
15 | GNU General Public License for more details. | 15 | GNU General Public License for more details. | ||
16 | 16 | | |||
17 | You should have received a copy of the GNU General Public License | 17 | You should have received a copy of the GNU General Public License | ||
18 | along with this program. If not, see <http://www.gnu.org/licenses/>. | 18 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
19 | *********************************************************************/ | 19 | *********************************************************************/ | ||
20 | #ifndef KWIN_VIRTUAL_OUTPUT_H | 20 | #ifndef KWIN_VIRTUAL_OUTPUT_H | ||
21 | #define KWIN_VIRTUAL_OUTPUT_H | 21 | #define KWIN_VIRTUAL_OUTPUT_H | ||
22 | 22 | | |||
23 | #include "output.h" | ||||
24 | | ||||
23 | #include <QObject> | 25 | #include <QObject> | ||
24 | #include <QRect> | 26 | #include <QRect> | ||
25 | 27 | | |||
26 | namespace KWin | 28 | namespace KWin | ||
27 | { | 29 | { | ||
28 | class VirtualBackend; | 30 | class VirtualBackend; | ||
29 | 31 | | |||
30 | class VirtualOutput : public QObject | 32 | class VirtualOutput : public Output | ||
31 | { | 33 | { | ||
32 | Q_OBJECT | 34 | Q_OBJECT | ||
33 | 35 | | |||
34 | public: | 36 | public: | ||
35 | VirtualOutput(QObject *parent = nullptr); | 37 | VirtualOutput(QObject *parent = nullptr); | ||
36 | virtual ~VirtualOutput(); | 38 | virtual ~VirtualOutput(); | ||
37 | 39 | | |||
38 | QRect geometry() const { | 40 | QSize pixelSize() const override; | ||
39 | return m_geo; | 41 | | ||
40 | } | 42 | void setGeometry(const QRect &geo); | ||
41 | 43 | | |||
42 | private: | 44 | private: | ||
43 | Q_DISABLE_COPY(VirtualOutput); | 45 | Q_DISABLE_COPY(VirtualOutput); | ||
44 | friend class VirtualBackend; | 46 | friend class VirtualBackend; | ||
45 | 47 | | |||
46 | QRect m_geo; | 48 | QSize m_pixelSize; | ||
47 | qreal m_outputScale = 1; | | |||
48 | 49 | | |||
49 | int m_gammaSize = 200; | 50 | int m_gammaSize = 200; | ||
50 | bool m_gammaResult = true; | 51 | bool m_gammaResult = true; | ||
51 | }; | 52 | }; | ||
52 | 53 | | |||
53 | } | 54 | } | ||
54 | 55 | | |||
55 | #endif | 56 | #endif |