diff options
| author | bakkeby <[email protected]> | 2020-03-22 10:55:43 +0100 |
|---|---|---|
| committer | bakkeby <[email protected]> | 2020-03-22 10:55:43 +0100 |
| commit | f401a51fa8b2a02d754b29cc39f4a6675f16a454 (patch) | |
| tree | 5911161b68a8b29cf219326fadd0fdde25f950ba | |
| parent | 9bc39c02b27a9ecc0bfe17bd1f917c31b07b95a2 (diff) | |
| download | dwm-flexipatch-f401a51fa8b2a02d754b29cc39f4a6675f16a454.tar.gz dwm-flexipatch-f401a51fa8b2a02d754b29cc39f4a6675f16a454.zip | |
Fix broken client when using systray without the alpha patch, ref. #18
| -rw-r--r-- | patch/systray.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/patch/systray.c b/patch/systray.c index 26d3de0..c2a04f0 100644 --- a/patch/systray.c +++ b/patch/systray.c @@ -87,7 +87,16 @@ updatesystray(void) InputOutput, visual, CWOverrideRedirect|CWBackPixel|CWBorderPixel|CWColormap|CWEventMask, &wa); #else - systray->win = XCreateSimpleWindow(dpy, root, x - xpad, m->by + ypad, w, bh, 0, 0, scheme[SchemeSel][ColBg].pixel); + XSetWindowAttributes wa = { + .override_redirect = True, + .background_pixel = scheme[SchemeNorm][ColBg].pixel, + .border_pixel = 0, + .colormap = DefaultColormap(dpy, screen), + .event_mask = ButtonPressMask|ExposureMask + }; + systray->win = XCreateWindow(dpy, root, x - xpad, m->by + ypad, w, bh, 0, DefaultDepth(dpy, screen), + InputOutput, DefaultVisual(dpy, screen), + CWOverrideRedirect|CWBackPixel|CWBorderPixel|CWColormap|CWEventMask, &wa); #endif // ALPHA_PATCH XSelectInput(dpy, systray->win, SubstructureNotifyMask); XChangeProperty(dpy, systray->win, netatom[NetSystemTrayOrientation], XA_CARDINAL, 32, |
