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.c21
1 files changed, 8 insertions, 13 deletions
diff --git a/event.c b/event.c
index cf89428..50c59a0 100644
--- a/event.c
+++ b/event.c
@@ -1,3 +1,4 @@
+#include <stdio.h>
 /*
  * (C)opyright MMVI Anselm R. Garbe <garbeam at gmail dot com>
  * See LICENSE file for license details.
@@ -38,6 +39,7 @@ movemouse(Client *c) {
 		XMaskEvent(dpy, MOUSEMASK | ExposureMask, &ev);
 		switch (ev.type) {
 		case ButtonRelease:
+			resize(c, True, TopLeft);
 			XUngrabPointer(dpy, CurrentTime);
 			return;
 		case Expose:
@@ -71,6 +73,7 @@ resizemouse(Client *c) {
 		XMaskEvent(dpy, MOUSEMASK | ExposureMask, &ev);
 		switch(ev.type) {
 		case ButtonRelease:
+			resize(c, True, TopLeft);
 			XUngrabPointer(dpy, CurrentTime);
 			return;
 		case Expose:
@@ -151,6 +154,7 @@ configurerequest(XEvent *e) {
 	XEvent synev;
 	XWindowChanges wc;
 
+	fputs("configurerequest\n", stderr);
 	if((c = getclient(ev->window))) {
 		c->ismax = False;
 		gravitate(c, True);
@@ -172,19 +176,8 @@ configurerequest(XEvent *e) {
 		newmask = ev->value_mask & (~(CWSibling | CWStackMode | CWBorderWidth));
 		if(newmask)
 			XConfigureWindow(dpy, c->win, newmask, &wc);
-		else {
-			synev.type = ConfigureNotify;
-			synev.xconfigure.display = dpy;
-			synev.xconfigure.event = c->win;
-			synev.xconfigure.window = c->win;
-			synev.xconfigure.x = c->x;
-			synev.xconfigure.y = c->y;
-			synev.xconfigure.width = c->w;
-			synev.xconfigure.height = c->h;
-			synev.xconfigure.border_width = c->border;
-			synev.xconfigure.above = None;
-			XSendEvent(dpy, c->win, True, NoEventMask, &synev);
-		}
+		else
+			configure(c);
 		XSync(dpy, False);
 		if(c->isfloat)
 			resize(c, False, TopLeft);
@@ -218,6 +211,7 @@ enternotify(XEvent *e) {
 	Client *c;
 	XCrossingEvent *ev = &e->xcrossing;
 
+	fputs("enternotify\n", stderr);
 	if(ev->mode != NotifyNormal || ev->detail == NotifyInferior)
 		return;
 
@@ -305,6 +299,7 @@ propertynotify(XEvent *e) {
 	Window trans;
 	XPropertyEvent *ev = &e->xproperty;
 
+	fputs("propertynotify\n", stderr);
 	if(ev->state == PropertyDelete)
 		return; /* ignore */
 
uthor Drew DeVault <sir@cmpwn.com> 2019-01-13 20:02:21 -0500 committer Drew DeVault <sir@cmpwn.com> 2019-01-13 20:02:21 -0500 Add loading spinner' href='/akspecs/aerc/commit/widgets/spinner.go?h=0.5.0&id=a782b709d1312bfe80dda7c864de96ba1c854bc2'>a782b70 ^
e4104a8 ^
a782b70 ^
e4104a8 ^


a782b70 ^




0f8b7a1 ^



2159eb8 ^

a782b70 ^



2159eb8 ^

a782b70 ^

2159eb8 ^
a782b70 ^






0f8b7a1 ^



2159eb8 ^

a782b70 ^



2159eb8 ^
a782b70 ^


0f8b7a1 ^
de36484 ^
0f8b7a1 ^

e4104a8 ^
2159eb8 ^
a782b70 ^
e4104a8 ^

a782b70 ^

a782b70 ^
5685a17 ^
a782b70 ^
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