diff options
author | nirav <nirav@airmail.cc> | 2020-06-14 17:20:06 +0000 |
---|---|---|
committer | nirav <nirav@airmail.cc> | 2020-06-14 17:20:06 +0000 |
commit | 76e037a07350a299e5281dd8ad0c4b2d30ae7667 (patch) | |
tree | 5180bc48dd66a443db6dba3fe17657e7ae8d33e9 | |
parent | d4746a642e1c0103f85d7c17bee6de028ba1e4c5 (diff) | |
download | dwm-76e037a07350a299e5281dd8ad0c4b2d30ae7667.tar.gz dwm-76e037a07350a299e5281dd8ad0c4b2d30ae7667.zip |
Revert "Add attachaside"
This reverts commit cf09a795390d2397ec3d8b3c9dd98429e852db7a.
-rw-r--r-- | README | 1 | ||||
-rw-r--r-- | dwm.c | 32 |
2 files changed, 4 insertions, 29 deletions
@@ -52,7 +52,6 @@ Patches applied Shiftview - https://lists.suckless.org/dev/1104/7590.html noborder - https://dwm.suckless.org/patches/noborder/ pertag - https://dwm.suckless.org/patches/pertag/ -attachaside - https://dwm.suckless.org/patches/attachaside/ scratchpad - https://dwm.suckless.org/patches/scratchpad/ movestack - https://dwm.suckless.org/patches/movestack/ dragmfact - https://dwm.suckless.org/patches/dragmfact/ @@ -49,8 +49,7 @@ #define CLEANMASK(mask) (mask & ~(numlockmask|LockMask) & (ShiftMask|ControlMask|Mod1Mask|Mod2Mask|Mod3Mask|Mod4Mask|Mod5Mask)) #define INTERSECT(x,y,w,h,m) (MAX(0, MIN((x)+(w),(m)->wx+(m)->ww) - MAX((x),(m)->wx)) \ * MAX(0, MIN((y)+(h),(m)->wy+(m)->wh) - MAX((y),(m)->wy))) -#define ISVISIBLEONTAG(C, T) ((C->tags & T)) -#define ISVISIBLE(C) ISVISIBLEONTAG(C, C->mon->tagset[C->mon->seltags]) +#define ISVISIBLE(C) ((C->tags & C->mon->tagset[C->mon->seltags])) #define LENGTH(X) (sizeof X / sizeof X[0]) #define MOUSEMASK (BUTTONMASK|PointerMotionMask) #define WIDTH(X) ((X)->w + 2 * (X)->bw) @@ -158,7 +157,6 @@ static int applysizehints(Client *c, int *x, int *y, int *w, int *h, int interac static void arrange(Monitor *m); static void arrangemon(Monitor *m); static void attach(Client *c); -static void attachaside(Client *c); static void attachstack(Client *c); static void buttonpress(XEvent *e); static void checkotherwm(void); @@ -198,7 +196,6 @@ static void maprequest(XEvent *e); static void monocle(Monitor *m); static void motionnotify(XEvent *e); static void movemouse(const Arg *arg); -static Client *nexttagged(Client *c); static Client *nexttiled(Client *c); static void pop(Client *); static void propertynotify(XEvent *e); @@ -440,17 +437,6 @@ attach(Client *c) } void -attachaside(Client *c) { - Client *at = nexttagged(c); - if(!at) { - attach(c); - return; - } - c->next = at->next; - at->next = c; -} - -void attachstack(Client *c) { c->snext = c->mon->stack; @@ -1267,7 +1253,7 @@ manage(Window w, XWindowAttributes *wa) c->isfloating = c->oldstate = trans != None || c->isfixed; if (c->isfloating) XRaiseWindow(dpy, c->win); - attachaside(c); + attach(c); attachstack(c); XChangeProperty(dpy, root, netatom[NetClientList], XA_WINDOW, 32, PropModeAppend, (unsigned char *) &(c->win), 1); @@ -1398,16 +1384,6 @@ movemouse(const Arg *arg) } Client * -nexttagged(Client *c) { - Client *walked = c->mon->clients; - for(; - walked && (walked->isfloating || !ISVISIBLEONTAG(walked, c->tags)); - walked = walked->next - ); - return walked; -} - -Client * nexttiled(Client *c) { for (; c && (c->isfloating || !ISVISIBLE(c)); c = c->next); @@ -1656,7 +1632,7 @@ sendmon(Client *c, Monitor *m) detachstack(c); c->mon = m; c->tags = m->tagset[m->seltags]; /* assign tags of target monitor */ - attachaside(c); + attach(c); attachstack(c); focus(NULL); arrange(NULL); @@ -2219,7 +2195,7 @@ updategeom(void) m->clients = c->next; detachstack(c); c->mon = mons; - attachaside(c); + attach(c); attachstack(c); } if (m == selmon) |