mirror of
https://github.com/alrayyes/dwm
synced 2023-11-14 15:56:31 +00:00
removed attachaside & re instated original dependencies
This commit is contained in:
parent
b13a8f7ac7
commit
dcd0d1f752
6
PKGBUILD
6
PKGBUILD
@ -9,14 +9,13 @@ url="http://dwm.suckless.org"
|
||||
arch=('i686' 'x86_64')
|
||||
license=('MIT')
|
||||
options=(zipman)
|
||||
depends=('libx11' 'libxinerama' 'libxft' 'freetype2' 'st' 'dmenu' 'nerd-fonts-source-code-pro' 'xautolock' 'xss-lock' 'xbindkeys' 'compton' 'feh' 'unclutter' 'redshift' 'dunst' 'slstatus-git' 'spotify' 'tmux' 'scrot' 'pulseaudio' 'xorg-xbacklight' 'yubikey-oath-dmenu' 'pass' 'menu-calc' 'xdotool' 'i3lock')
|
||||
depends=('libx11' 'libxinerama' 'libxft' 'freetype2' 'st' 'dmenu')
|
||||
optdepends=('corrupter')
|
||||
install=dwm.install
|
||||
|
||||
_patches=(
|
||||
"dwm-systray-20190208-cb3f58a.diff"
|
||||
"dwm-noborder-20170207-bb3bd6f.diff"
|
||||
"dwm-attachaside-20180126-db22360.diff"
|
||||
"dwm-autostart-20161205-bb3bd6f.diff"
|
||||
"dwm-cyclelayouts-20180524-6.2.diff"
|
||||
"dwm-gridmode-20170909-ceac8c9.diff"
|
||||
@ -25,7 +24,6 @@ _patches=(
|
||||
"local-statuscolors-20181008-b69c870.diff"
|
||||
"local-fancybar-2019018-b69c870.diff"
|
||||
"local-scratchpad-20170207-bb3bd6f.diff"
|
||||
# "local-notitle-6.2.diff"
|
||||
"local-alpha-20180613-b69c870.diff"
|
||||
)
|
||||
|
||||
@ -54,7 +52,7 @@ md5sums=('9929845ccdec4d2cc191f16210dd7f3d'
|
||||
|
||||
prepare() {
|
||||
cd $srcdir/$pkgname-$pkgver
|
||||
sed -i "25 a \ \t{ NULL, NULL }," "$srcdir/$(basename ${_patches[5]})"
|
||||
sed -i "25 a \ \t{ NULL, NULL }," "$srcdir/$(basename ${_patches[4]})"
|
||||
|
||||
for patch in "${_patches[@]}"; do
|
||||
echo "Applying patch $(basename $patch)..."
|
||||
|
@ -4,7 +4,6 @@
|
||||
|
||||
+ [systray](https://dwm.suckless.org/patches/systray/)
|
||||
+ [noborder](https://dwm.suckless.org/patches/noborder/)
|
||||
+ [attachaside](https://dwm.suckless.org/patches/attachaside)
|
||||
+ [autostart](https://dwm.suckless.org/patches/autostart/)
|
||||
+ [cyclelayouts](https://dwm.suckless.org/patches/cyclelayouts/)
|
||||
+ [gridmode](https://dwm.suckless.org/patches/gridmode/)
|
||||
|
@ -1,92 +0,0 @@
|
||||
diff --git a/dwm.c b/dwm.c
|
||||
index ec6a27c..7b6ce67 100644
|
||||
--- a/dwm.c
|
||||
+++ b/dwm.c
|
||||
@@ -49,7 +49,8 @@
|
||||
#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 ISVISIBLE(C) ((C->tags & C->mon->tagset[C->mon->seltags]))
|
||||
+#define ISVISIBLEONTAG(C, T) ((C->tags & T))
|
||||
+#define ISVISIBLE(C) ISVISIBLEONTAG(C, 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)
|
||||
@@ -148,6 +149,7 @@ 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);
|
||||
@@ -184,6 +186,7 @@ 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);
|
||||
@@ -407,6 +410,18 @@ attach(Client *c)
|
||||
c->mon->clients = 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)
|
||||
{
|
||||
@@ -1063,7 +1078,7 @@ manage(Window w, XWindowAttributes *wa)
|
||||
c->isfloating = c->oldstate = trans != None || c->isfixed;
|
||||
if (c->isfloating)
|
||||
XRaiseWindow(dpy, c->win);
|
||||
- attach(c);
|
||||
+ attachaside(c);
|
||||
attachstack(c);
|
||||
XChangeProperty(dpy, root, netatom[NetClientList], XA_WINDOW, 32, PropModeAppend,
|
||||
(unsigned char *) &(c->win), 1);
|
||||
@@ -1193,6 +1208,16 @@ 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)
|
||||
{
|
||||
@@ -1418,7 +1443,7 @@ sendmon(Client *c, Monitor *m)
|
||||
detachstack(c);
|
||||
c->mon = m;
|
||||
c->tags = m->tagset[m->seltags]; /* assign tags of target monitor */
|
||||
- attach(c);
|
||||
+ attachaside(c);
|
||||
attachstack(c);
|
||||
focus(NULL);
|
||||
arrange(NULL);
|
||||
@@ -1899,6 +1924,7 @@ updategeom(void)
|
||||
detachstack(c);
|
||||
c->mon = mons;
|
||||
attach(c);
|
||||
+ attachaside(c);
|
||||
attachstack(c);
|
||||
}
|
||||
if (m == selmon)
|
Loading…
Reference in New Issue
Block a user