diff options
| author | ProsperousPotato <ProsperousPotato@users.noreply.github.com> | 2025-10-25 23:30:54 +0100 |
|---|---|---|
| committer | ProsperousPotato <ProsperousPotato@users.noreply.github.com> | 2025-10-25 23:30:54 +0100 |
| commit | 88e0b350a366281184716f98d31cd25a8f5fc782 (patch) | |
| tree | 8c16b7881692ab502aa0d418bb0f801d3944ce49 | |
| parent | dfa6aebfc19c98f062a1335b981723628fb6066a (diff) | |
fix monocle layout, and remove commented code
| -rw-r--r-- | config.mk | 5 | ||||
| -rw-r--r-- | dwm.c | 6 |
2 files changed, 5 insertions, 6 deletions
@@ -17,6 +17,7 @@ XINERAMAFLAGS = -DXINERAMA # freetype FREETYPELIBS = -lfontconfig -lXft FREETYPEINC = /usr/include/freetype2 + # OpenBSD # FREETYPEINC = ${X11INC}/freetype2 # MANPREFIX = ${PREFIX}/man @@ -31,9 +32,5 @@ CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700L -DVERSION=\"${VE CFLAGS = -std=c99 -pedantic -Wall -Wno-deprecated-declarations -O3 -march=native -mtune=native ${INCS} ${CPPFLAGS} LDFLAGS = ${LIBS} -# Solaris -#CFLAGS = -fast ${INCS} -DVERSION=\"${VERSION}\" -#LDFLAGS = ${LIBS} - # compiler and linker CC = cc @@ -494,8 +494,7 @@ buttonpress(XEvent *e) selmon = m; focus(NULL); } - // if (ev->window == selmon->barwin) { - /* } else */ if ((c = wintoclient(ev->window))) { + if ((c = wintoclient(ev->window))) { focus(c); restack(selmon); XAllowEvents(dpy, ReplayPointer, CurrentTime); @@ -784,6 +783,9 @@ focus(Client *c) XSetWindowBorder(dpy, c->win, scheme[SchemeSel][ColBorder].pixel); } setfocus(c); + + if (selmon->lt[selmon->sellt]->arrange == monocle) + XRaiseWindow(dpy, c->win); } else { XSetInputFocus(dpy, root, RevertToPointerRoot, CurrentTime); XDeleteProperty(dpy, root, netatom[NetActiveWindow]); |
