about summary refs log tree commit diff stats
path: root/event.c
diff options
context:
space:
mode:
Diffstat (limited to 'event.c')
-rw-r--r--event.c36
1 files changed, 20 insertions, 16 deletions
diff --git a/event.c b/event.c
index 4928f25..8a3d99a 100644
--- a/event.c
+++ b/event.c
@@ -170,28 +170,32 @@ configurerequest(XEvent *e) {
 	XConfigureRequestEvent *ev = &e->xconfigurerequest;
 	XWindowChanges wc;
 
-	wc.x = ev->x;
-	wc.y = ev->y;
-	wc.width = ev->width;
-	wc.height = ev->height;
-	wc.border_width = ev->border_width;
-	wc.sibling = ev->above;
-	wc.stack_mode = ev->detail;
 	if((c = getclient(ev->window))) {
 		c->ismax = False;
-		if(ev->value_mask & CWBorderWidth)
-			c->border = ev->border_width;
+		c->border = (ev->value_mask & CWBorderWidth) ? ev->border_width : c->border;
 		if((!c->isfloat && (arrange != dofloat))
-			|| ((ev->value_mask & (CWX|CWY)) && !(ev->value_mask & (CWWidth|CWHeight))))
-		{
+			|| ((ev->value_mask & (CWX | CWY)) && !(ev->value_mask & (CWWidth | CWHeight))))
 			configure(c);
-			XSync(dpy, False);
-			return;
+		else {
+			c->x = (ev->value_mask & CWX) ? ev->x : c->x;
+			c->y = (ev->value_mask & CWY) ? ev->y : c->y;
+			c->w = (ev->value_mask & CWWidth) ? ev->width : c->w;
+			c->h = (ev->value_mask & CWHeight) ? ev->height : c->h;
+			resize(c, False);
+			if(!isvisible(c))
+				XMoveWindow(dpy, c->win, c->x + 2 * sw, c->y);
 		}
 	}
-	XConfigureWindow(dpy, ev->window, ev->value_mask, &wc);
-	if(c && !isvisible(c))
-		XMoveWindow(dpy, c->win, c->x + 2 * sw, c->y);
+	else {
+		wc.x = ev->x;
+		wc.y = ev->y;
+		wc.width = ev->width;
+		wc.height = ev->height;
+		wc.border_width = ev->border_width;
+		wc.sibling = ev->above;
+		wc.stack_mode = ev->detail;
+		XConfigureWindow(dpy, ev->window, ev->value_mask, &wc);
+	}
 	XSync(dpy, False);
 }
 
+0100 changed some odering in config*.h' href='/acidbong/suckless/dwm/commit/config.default.h?h=4.5&id=3794c6294535518fdcdf2ceb434875584189aa1e'>3794c62 ^
f196b71 ^



5871008 ^
f196b71 ^



3794c62 ^
f196b71 ^
3794c62 ^
f196b71 ^
3794c62 ^

5871008 ^
3794c62 ^
ef9b3e1 ^
f196b71 ^
cac492b ^
3794c62 ^
f196b71 ^

b515765 ^
b515765 ^
19dcbc5 ^
2c477cf ^



ef9b3e1 ^

27b0595 ^

2c477cf ^

5871008 ^
2c477cf ^







































b515765 ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96