From f5f8423364a13a455c18e32d9bb96e4c4c42e68d Mon Sep 17 00:00:00 2001 From: o9000 Date: Sat, 22 Jul 2017 09:22:27 +0200 Subject: [PATCH] panel: Set _NET_WM_PID (fixes issue #651) --- src/panel.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/panel.c b/src/panel.c index cb7afa3..e6057ab 100644 --- a/src/panel.c +++ b/src/panel.c @@ -20,6 +20,8 @@ #include #include #include +#include +#include #include #include #include @@ -814,15 +816,24 @@ void set_panel_properties(Panel *p) g_free(name); } + long pid = getpid(); + XChangeProperty(server.display, + p->main_win, + server.atom._NET_WM_PID, + XA_CARDINAL, + 32, + PropModeReplace, + (unsigned char *)&pid, + 1); + // Dock - long val = server.atom._NET_WM_WINDOW_TYPE_DOCK; XChangeProperty(server.display, p->main_win, server.atom._NET_WM_WINDOW_TYPE, XA_ATOM, 32, PropModeReplace, - (unsigned char *)&val, + (unsigned char *)&server.atom._NET_WM_WINDOW_TYPE_DOCK, 1); place_panel_all_desktops(p);