[wiki] [sites] Updating autoresize patch || blut
commit 17f6bb3379099bb24dd9dec32cebf675d1977a29
Author: blut <blut.hannes_AT_gmail.com>
Date: Wed May 15 07:14:10 2013 +0200
Updating autoresize patch
diff --git a/dwm.suckless.org/patches/autoresize.md b/dwm.suckless.org/patches/autoresize.md
index 66ce83d..02baeb5 100644
--- a/dwm.suckless.org/patches/autoresize.md
+++ b/dwm.suckless.org/patches/autoresize.md
_AT_@ -7,6 +7,7 @@ By default, windows that are not visible when requesting a resize/move wont get
## Download
* [autoresize.diff](autoresize.diff) autoresize.diff (07.03.2010)
+ * [dwm-6.0-autoresize.diff](dwm-6.0-autoresize.diff) (15.04.2013)
## Author
diff --git a/dwm.suckless.org/patches/dwm-6.0-autoresize.diff b/dwm.suckless.org/patches/dwm-6.0-autoresize.diff
new file mode 100644
index 0000000..4bb3104
--- /dev/null
+++ b/dwm.suckless.org/patches/dwm-6.0-autoresize.diff
_AT_@ -0,0 +1,35 @@
+diff --git a/dwm.c b/dwm.c
+index e3bf6f4..8a2c646 100644
+--- a/dwm.c
++++ b/dwm.c
+_AT_@ -91,7 +91,7 @@ struct Client {
+ int basew, baseh, incw, inch, maxw, maxh, minw, minh;
+ int bw, oldbw;
+ unsigned int tags;
+- Bool isfixed, isfloating, isurgent, neverfocus, oldstate, isfullscreen;
++ Bool isfixed, isfloating, isurgent, neverfocus, oldstate, isfullscreen, needresize;
+ Client *next;
+ Client *snext;
+ Monitor *mon;
+_AT_@ -633,6 +633,8 @@ configurerequest(XEvent *e) {
+ configure(c);
+ if(ISVISIBLE(c))
+ XMoveResizeWindow(dpy, c->win, c->x, c->y, c->w, c->h);
++ else
++ c->needresize=1;
+ }
+ else
+ configure(c);
+_AT_@ -1663,6 +1665,12 @@ showhide(Client *c) {
+ return;
+ if(ISVISIBLE(c)) { /* show clients top down */
+ XMoveWindow(dpy, c->win, c->x, c->y);
++ if(c->needresize) {
++ c->needresize=0;
++ XMoveResizeWindow(dpy, c->win, c->x, c->y, c->w, c->h);
++ } else {
++ XMoveWindow(dpy, c->win, c->x, c->y);
++ }
+ if((!c->mon->lt[c->mon->sellt]->arrange || c->isfloating) && !c->isfullscreen)
+ resize(c, c->x, c->y, c->w, c->h, False);
+ showhide(c->snext);
Received on Wed May 15 2013 - 07:14:34 CEST
This archive was generated by hypermail 2.3.0
: Wed May 15 2013 - 07:24:18 CEST