Expose the toplevel's pid in the scripting API
This allows scripts to obtain the process behind a window, which can be useful for doing app-specific things in a script.
This commit is contained in:
parent
90b53f416c
commit
fb118a9343
1 changed files with 7 additions and 0 deletions
|
@ -284,6 +284,13 @@ class KWIN_EXPORT Toplevel : public QObject
|
|||
*/
|
||||
Q_PROPERTY(QUuid internalId READ internalId CONSTANT)
|
||||
|
||||
/**
|
||||
* The pid of the process owning this window.
|
||||
*
|
||||
* @since 5.20
|
||||
*/
|
||||
Q_PROPERTY(int pid READ pid CONSTANT)
|
||||
|
||||
public:
|
||||
explicit Toplevel();
|
||||
virtual xcb_window_t frameId() const;
|
||||
|
|
Loading…
Reference in a new issue