Changeset View
Changeset View
Standalone View
Standalone View
abstract_wayland_output.h
Show First 20 Lines • Show All 59 Lines • ▼ Show 20 Line(s) | 58 | public: | |||
---|---|---|---|---|---|
60 | ~AbstractWaylandOutput() override; | 60 | ~AbstractWaylandOutput() override; | ||
61 | 61 | | |||
62 | QString name() const override; | 62 | QString name() const override; | ||
63 | bool isEnabled() const { | 63 | bool isEnabled() const { | ||
64 | return !m_waylandOutput.isNull(); | 64 | return !m_waylandOutput.isNull(); | ||
65 | } | 65 | } | ||
66 | 66 | | |||
67 | virtual QSize pixelSize() const = 0; | 67 | virtual QSize pixelSize() const = 0; | ||
68 | qreal scale() const override { | 68 | qreal scale() const override; | ||
69 | return m_scale; | 69 | | ||
70 | } | | |||
71 | /** | 70 | /** | ||
72 | * The geometry of this output in global compositor co-ordinates (i.e scaled) | 71 | * The geometry of this output in global compositor co-ordinates (i.e scaled) | ||
73 | */ | 72 | */ | ||
74 | QRect geometry() const override; | 73 | QRect geometry() const override; | ||
75 | QSize physicalSize() const override; | 74 | QSize physicalSize() const override; | ||
76 | Qt::ScreenOrientation orientation() const override { | 75 | Qt::ScreenOrientation orientation() const override { | ||
77 | return m_orientation; | 76 | return m_orientation; | ||
78 | } | 77 | } | ||
▲ Show 20 Lines • Show All 41 Lines • ▼ Show 20 Line(s) | 118 | QPointer<KWayland::Server::XdgOutputInterface> xdgOutput() const { | |||
120 | return m_xdgOutput; | 119 | return m_xdgOutput; | ||
121 | } | 120 | } | ||
122 | void createXdgOutput(); | 121 | void createXdgOutput(); | ||
123 | 122 | | |||
124 | QPointer<KWayland::Server::OutputDeviceInterface> waylandOutputDevice() const { | 123 | QPointer<KWayland::Server::OutputDeviceInterface> waylandOutputDevice() const { | ||
125 | return m_waylandOutputDevice; | 124 | return m_waylandOutputDevice; | ||
126 | } | 125 | } | ||
127 | 126 | | |||
128 | QPoint globalPos() const { | 127 | QPoint globalPos() const; | ||
129 | return m_globalPos; | | |||
130 | } | | |||
131 | 128 | | |||
132 | QSize rawPhysicalSize() const { | 129 | QSize rawPhysicalSize() const { | ||
133 | return m_physicalSize; | 130 | return m_physicalSize; | ||
134 | } | 131 | } | ||
135 | void setRawPhysicalSize(const QSize &set) { | 132 | void setRawPhysicalSize(const QSize &set) { | ||
136 | m_physicalSize = set; | 133 | m_physicalSize = set; | ||
137 | } | 134 | } | ||
138 | 135 | | |||
Show All 25 Lines | |||||
164 | 161 | | |||
165 | private: | 162 | private: | ||
166 | QPointer<KWayland::Server::OutputInterface> m_waylandOutput; | 163 | QPointer<KWayland::Server::OutputInterface> m_waylandOutput; | ||
167 | QPointer<KWayland::Server::XdgOutputInterface> m_xdgOutput; | 164 | QPointer<KWayland::Server::XdgOutputInterface> m_xdgOutput; | ||
168 | QPointer<KWayland::Server::OutputDeviceInterface> m_waylandOutputDevice; | 165 | QPointer<KWayland::Server::OutputDeviceInterface> m_waylandOutputDevice; | ||
169 | 166 | | |||
170 | KWayland::Server::OutputInterface::DpmsMode m_dpms = KWayland::Server::OutputInterface::DpmsMode::On; | 167 | KWayland::Server::OutputInterface::DpmsMode m_dpms = KWayland::Server::OutputInterface::DpmsMode::On; | ||
171 | 168 | | |||
172 | QPoint m_globalPos; | | |||
173 | qreal m_scale = 1; | | |||
174 | QSize m_physicalSize; | 169 | QSize m_physicalSize; | ||
175 | Qt::ScreenOrientation m_orientation = Qt::PrimaryOrientation; | 170 | Qt::ScreenOrientation m_orientation = Qt::PrimaryOrientation; | ||
176 | bool m_internal = false; | 171 | bool m_internal = false; | ||
177 | bool m_supportsDpms = false; | 172 | bool m_supportsDpms = false; | ||
178 | }; | 173 | }; | ||
179 | 174 | | |||
180 | } | 175 | } | ||
181 | 176 | | |||
182 | #endif // KWIN_OUTPUT_H | 177 | #endif // KWIN_OUTPUT_H |