Commit fe6c2960 authored by Nicolas Fella's avatar Nicolas Fella Committed by Nicolas Fella

[libkwineffects] Add windowId to EffectWindow

My use case is integrating with a system that tracks window properties based on the windowId. This allows the effect to do window-specific things.
parent 3281569c
......@@ -253,6 +253,9 @@ public:
pid_t pid() const override {
return 0;
}
qlonglong windowId() const override {
return 0;
}
private:
qreal m_opacity = 1.0;
......
......@@ -1828,6 +1828,7 @@ TOPLEVEL_HELPER(KWaylandServer::SurfaceInterface *, surface, surface)
TOPLEVEL_HELPER(bool, isPopupWindow, isPopupWindow)
TOPLEVEL_HELPER(bool, isOutline, isOutline)
TOPLEVEL_HELPER(pid_t, pid, pid)
TOPLEVEL_HELPER(qlonglong, windowId, window)
#undef TOPLEVEL_HELPER
......
......@@ -454,6 +454,7 @@ public:
bool isX11Client() const override;
pid_t pid() const override;
qlonglong windowId() const override;
QRect decorationInnerRect() const override;
QByteArray readProperty(long atom, long type, int format) const override;
......
......@@ -2438,6 +2438,11 @@ public:
*/
virtual pid_t pid() const = 0;
/**
* @since 5.21
*/
virtual qlonglong windowId() const = 0;
/**
* Can be used to by effects to store arbitrary data in the EffectWindow.
*
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment