summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2019-09-20 23:18:17 +0200
committerGitHub <noreply@github.com>2019-09-20 23:18:17 +0200
commit42af54ff758d51b212c3b45ed89480f2f51535a2 (patch)
tree4992369badfee72bf0758b0568adfc27e7616151
parentb6bcc143adf8108c45bb29c4f399c449080b04b0 (diff)
parent4553935f27bb635bd043434f6c8be03b4939a25d (diff)
Merge pull request #32087 from karroffel/x11-pid
[X11] set PID as window attribute
-rw-r--r--platform/x11/os_x11.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/platform/x11/os_x11.cpp b/platform/x11/os_x11.cpp
index dfa0a45538..20502b61d9 100644
--- a/platform/x11/os_x11.cpp
+++ b/platform/x11/os_x11.cpp
@@ -378,6 +378,13 @@ Error OS_X11::initialize(const VideoMode &p_desired, int p_video_driver, int p_a
XChangeProperty(x11_display, x11_window, property, property, 32, PropModeReplace, (unsigned char *)&hints, 5);
}
+ // make PID known to X11
+ {
+ const long pid = this->get_process_id();
+ Atom net_wm_pid = XInternAtom(x11_display, "_NET_WM_PID", False);
+ XChangeProperty(x11_display, x11_window, net_wm_pid, XA_CARDINAL, 32, PropModeReplace, (unsigned char *)&pid, 1);
+ }
+
// disable resizable window
if (!current_videomode.resizable && !current_videomode.fullscreen) {
XSizeHints *xsh;