Changeset View
Changeset View
Standalone View
Standalone View
abstract_wayland_output.h
Show First 20 Lines • Show All 118 Lines • ▼ Show 20 Line(s) | 58 | public: | |||
---|---|---|---|---|---|
119 | /** | 119 | /** | ||
120 | * Enable or disable the output. | 120 | * Enable or disable the output. | ||
121 | * | 121 | * | ||
122 | * This differs from updateDpms as it also removes the wl_output. | 122 | * This differs from updateDpms as it also removes the wl_output. | ||
123 | * The default is on. | 123 | * The default is on. | ||
124 | */ | 124 | */ | ||
125 | void setEnabled(bool enable) override; | 125 | void setEnabled(bool enable) override; | ||
126 | 126 | | |||
127 | QString description() const; | ||||
128 | | ||||
127 | Q_SIGNALS: | 129 | Q_SIGNALS: | ||
128 | void modeChanged(); | 130 | void modeChanged(); | ||
129 | 131 | | |||
130 | protected: | 132 | protected: | ||
131 | void initInterfaces(const QString &model, const QString &manufacturer, | 133 | void initInterfaces(const QString &model, const QString &manufacturer, | ||
132 | const QByteArray &uuid, const QSize &physicalSize, | 134 | const QByteArray &uuid, const QSize &physicalSize, | ||
133 | const QVector<KWayland::Server::OutputDeviceInterface::Mode> &modes); | 135 | const QVector<KWayland::Server::OutputDeviceInterface::Mode> &modes); | ||
134 | 136 | | |||
135 | QPoint globalPos() const; | 137 | QPoint globalPos() const; | ||
136 | 138 | | |||
137 | bool internal() const { | 139 | bool internal() const { | ||
138 | return m_internal; | 140 | return m_internal; | ||
139 | } | 141 | } | ||
142 | void setName(const QString &name) { | ||||
143 | m_name = name; | ||||
144 | } | ||||
140 | void setInternal(bool set) { | 145 | void setInternal(bool set) { | ||
141 | m_internal = set; | 146 | m_internal = set; | ||
142 | } | 147 | } | ||
143 | void setDpmsSupported(bool set) { | 148 | void setDpmsSupported(bool set) { | ||
144 | m_waylandOutput->setDpmsSupported(set); | 149 | m_waylandOutput->setDpmsSupported(set); | ||
145 | } | 150 | } | ||
146 | 151 | | |||
147 | virtual void updateEnablement(bool enable) { | 152 | virtual void updateEnablement(bool enable) { | ||
Show All 17 Lines | |||||
165 | private: | 170 | private: | ||
166 | void setTransform(KWayland::Server::OutputDeviceInterface::Transform transform); | 171 | void setTransform(KWayland::Server::OutputDeviceInterface::Transform transform); | ||
167 | 172 | | |||
168 | KWayland::Server::OutputInterface *m_waylandOutput; | 173 | KWayland::Server::OutputInterface *m_waylandOutput; | ||
169 | KWayland::Server::XdgOutputInterface *m_xdgOutput; | 174 | KWayland::Server::XdgOutputInterface *m_xdgOutput; | ||
170 | KWayland::Server::OutputDeviceInterface *m_waylandOutputDevice; | 175 | KWayland::Server::OutputDeviceInterface *m_waylandOutputDevice; | ||
171 | KWayland::Server::OutputInterface::DpmsMode m_dpms = KWayland::Server::OutputInterface::DpmsMode::On; | 176 | KWayland::Server::OutputInterface::DpmsMode m_dpms = KWayland::Server::OutputInterface::DpmsMode::On; | ||
172 | 177 | | |||
178 | QString m_name; | ||||
173 | bool m_internal = false; | 179 | bool m_internal = false; | ||
174 | }; | 180 | }; | ||
175 | 181 | | |||
176 | } | 182 | } | ||
177 | 183 | | |||
178 | #endif // KWIN_OUTPUT_H | 184 | #endif // KWIN_OUTPUT_H |