Changeset View
Changeset View
Standalone View
Standalone View
src/client/shell.h
Show First 20 Lines • Show All 241 Lines • ▼ Show 20 Line(s) | 187 | public: | |||
---|---|---|---|---|---|
242 | * | 242 | * | ||
243 | * @param parent The parent Surface of this surface | 243 | * @param parent The parent Surface of this surface | ||
244 | * @param offset The offset of this Surface in the parent coordinate system | 244 | * @param offset The offset of this Surface in the parent coordinate system | ||
245 | * @param flags The flags for the transient | 245 | * @param flags The flags for the transient | ||
246 | * @since 5.5 | 246 | * @since 5.5 | ||
247 | **/ | 247 | **/ | ||
248 | void setTransient(Surface *parent, const QPoint &offset = QPoint(), TransientFlags flags = TransientFlag::Default); | 248 | void setTransient(Surface *parent, const QPoint &offset = QPoint(), TransientFlags flags = TransientFlag::Default); | ||
249 | 249 | | |||
250 | /** | ||||
251 | * Sets this Surface as a popup transient for @p parent. | ||||
252 | * | ||||
253 | * A popup is a transient with an added pointer grab on the @p grabbedSeat. | ||||
254 | * | ||||
255 | * The popup grab can be created if the client has an implicit grab (e.g. button press) | ||||
256 | * on the @p grabbedSeat. It needs to pass the @p grabSerial indicating the implicit grab | ||||
257 | * to the request for setting the surface. The implicit grab is turned into a popup grab | ||||
258 | * which will persist after the implicit grab ends. The popup grab ends when the ShellSurface | ||||
259 | * gets destroyed or when the compositor breaks the grab through the @link{popupDone} signal. | ||||
260 | * | ||||
261 | * @param parent The parent Surface of this ShellSurface | ||||
262 | * @param grabbedSeat The Seat on which an implicit grab exists | ||||
263 | * @param grabSerial The serial of the implicit grab | ||||
264 | * @param offset The offset of this Surface in the parent coordinate system | ||||
265 | * @param flags The flags for the transient | ||||
266 | * @since 5.33 | ||||
267 | **/ | ||||
268 | void setTransientPopup(Surface *parent, Seat *grabbedSeat, quint32 grabSerial, const QPoint &offset = QPoint(), TransientFlags flags = TransientFlag::Default); | ||||
269 | | ||||
250 | bool isValid() const; | 270 | bool isValid() const; | ||
251 | 271 | | |||
252 | /** | 272 | /** | ||
253 | * Requests a move on the given @p seat after the pointer button press with the given @p serial. | 273 | * Requests a move on the given @p seat after the pointer button press with the given @p serial. | ||
254 | * | 274 | * | ||
255 | * @param seat The seat on which to move the window | 275 | * @param seat The seat on which to move the window | ||
256 | * @param serial The serial of the pointer button press which should trigger the move | 276 | * @param serial The serial of the pointer button press which should trigger the move | ||
257 | * @since 5.5 | 277 | * @since 5.5 | ||
▲ Show 20 Lines • Show All 45 Lines • ▼ Show 20 Line(s) | |||||
303 | Q_SIGNALS: | 323 | Q_SIGNALS: | ||
304 | /** | 324 | /** | ||
305 | * Signal is emitted when the ShellSurface received a ping request. | 325 | * Signal is emitted when the ShellSurface received a ping request. | ||
306 | * The ShellSurface automatically responds to the ping. | 326 | * The ShellSurface automatically responds to the ping. | ||
307 | **/ | 327 | **/ | ||
308 | void pinged(); | 328 | void pinged(); | ||
309 | void sizeChanged(const QSize &); | 329 | void sizeChanged(const QSize &); | ||
310 | 330 | | |||
331 | /** | ||||
332 | * The popupDone signal is sent out when a popup grab is broken, that is, | ||||
333 | * when the user clicks a surface that doesn't belong to the client owning | ||||
334 | * the popup surface. | ||||
335 | * @see setTransientPopup | ||||
336 | * @since 5.33 | ||||
337 | **/ | ||||
338 | void popupDone(); | ||||
339 | | ||||
311 | private: | 340 | private: | ||
312 | class Private; | 341 | class Private; | ||
313 | QScopedPointer<Private> d; | 342 | QScopedPointer<Private> d; | ||
314 | }; | 343 | }; | ||
315 | 344 | | |||
316 | } | 345 | } | ||
317 | } | 346 | } | ||
318 | 347 | | |||
319 | Q_DECLARE_METATYPE(KWayland::Client::ShellSurface::TransientFlag) | 348 | Q_DECLARE_METATYPE(KWayland::Client::ShellSurface::TransientFlag) | ||
320 | Q_DECLARE_METATYPE(KWayland::Client::ShellSurface::TransientFlags) | 349 | Q_DECLARE_METATYPE(KWayland::Client::ShellSurface::TransientFlags) | ||
321 | 350 | | |||
322 | #endif | 351 | #endif |