commit c12d8eb003585064fb7dc484597e02abe17a0e80
parent 48e4fcbdfcb75352f6d1dc9657cc6eabe842b984
Author: Dylan Araps <dylan.araps@gmail.com>
Date: Sun, 13 Oct 2019 21:59:52 +0300
docs: update
Diffstat:
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/sowm.c b/sowm.c
@@ -66,7 +66,7 @@ static void run(const Arg arg);
static client *list = { 0 };
static ws ws_list[10];
-static int desk = 1, sh, sw, s, junk;
+static int desk = 1, sh, sw, s, j;
static Display *dis;
static Window root, cur;
@@ -104,6 +104,8 @@ void notify_motion(XEvent *e) {
int xdiff = e->xbutton.x_root - start.x_root;
int ydiff = e->xbutton.y_root - start.y_root;
+ while(XCheckTypedEvent(dis, MotionNotify, e));
+
XMoveResizeWindow(dis, start.subwindow,
attr.x + (start.button==1 ? xdiff : 0),
attr.y + (start.button==1 ? ydiff : 0),
@@ -144,7 +146,7 @@ void button_release() {
}
Window win_current() {
- XGetInputFocus(dis, &cur, &junk);
+ XGetInputFocus(dis, &cur, &j);
return cur;
}