// File: /workspace/github_c_makefile_star2_O1/kek[P]evilwm/screen.c
// Function: sweep
void sweep(Client *c) {
	XEvent ev;
	int old_cx = c->x;
	int old_cy = c->y;

	if (!grab_pointer(c->screen->root, MouseMask, resize_curs)) return;

	client_raise(c);
#ifdef INFOBANNER_MOVERESIZE
	create_info_window(c);
#endif
	XGrabServer(dpy);
	draw_outline(c);

	setmouse(c->window, c->width, c->height);
	for (;;) {
		XMaskEvent(dpy, MouseMask, &ev);
		switch (ev.type) {
			case MotionNotify:
				if (ev.xmotion.root != c->screen->root)
					break;
				draw_outline(c); /* clear */
				XUngrabServer(dpy);
				recalculate_sweep(c, old_cx, old_cy, ev.xmotion.x, ev.xmotion.y, ev.xmotion.state & altmask);
#ifdef INFOBANNER_MOVERESIZE
				update_info_window(c);
#endif
				XSync(dpy, False);
				XGrabServer(dpy);
				draw_outline(c);
				break;
			case ButtonRelease:
				draw_outline(c); /* clear */
				XUngrabServer(dpy);
#ifdef INFOBANNER_MOVERESIZE
				remove_info_window();
#endif
				XUngrabPointer(dpy, CurrentTime);
				moveresize(c);
				/* In case maximise state has changed: */
				ewmh_set_net_wm_state(c);
				return;
			default: break;
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %rdi, %rbx
movl 0x24(%rdi), %ebp
movl 0x28(%rdi), %r12d
leaq 0x5716(%rip), %r15      # 0xc7e0
movq (%r15), %rdi
movq 0x10(%rbx), %rax
movq 0x8(%rax), %rsi
leaq 0x572c(%rip), %rax      # 0xc808
subq $0x8, %rsp
xorl %r13d, %r13d
xorl %edx, %edx
movl $0x4c, %ecx
movl $0x1, %r8d
movl $0x1, %r9d
pushq %r13
pushq (%rax)
pushq %r13
callq 0x32a0
addq $0x20, %rsp
testl %eax, %eax
jne 0x72a4
movq %rbx, %rdi
callq 0x3ae2
movq (%r15), %rdi
callq 0x34b0
movq %rbx, %rdi
callq 0x72b6
movq (%r15), %rdi
movq (%rbx), %rdx
movl 0x2c(%rbx), %eax
movl 0x30(%rbx), %r10d
subq $0x8, %rsp
xorl %esi, %esi
xorl %ecx, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
pushq %r10
pushq %rax
pushq $0x0
callq 0x32c0
addq $0x20, %rsp
leaq 0x8(%rsp), %r14
movq (%r15), %rdi
movl $0x4c, %esi
movq %r14, %rdx
callq 0x3730
movl 0x8(%rsp), %eax
cmpl $0x6, %eax
je 0x7176
cmpl $0x5, %eax
jne 0x7153
jmp 0x727a
movq 0x30(%rsp), %rax
movq 0x10(%rbx), %rcx
cmpq 0x8(%rcx), %rax
jne 0x7153
movq %rbx, %rdi
callq 0x72b6
movq (%r15), %rdi
callq 0x33f0
movl 0x48(%rsp), %esi
leaq 0x5238(%rip), %rax      # 0xc3d8
movl (%rax), %ecx
andl 0x58(%rsp), %ecx
je 0x71f8
movl %ebp, %eax
subl %esi, %eax
movl %eax, %edi
negl %edi
cmovsl %eax, %edi
movl %edi, %eax
subl 0x60(%rbx), %eax
cltd
idivl 0x58(%rbx)
subl %edx, %edi
movl 0x48(%rbx), %edx
movl %edi, %eax
cmpl %edx, %edi
jg 0x71c9
movl %edx, %eax
movl 0x50(%rbx), %r8d
testl %edx, %edx
cmovel %edi, %eax
movl %eax, %edx
cmpl %r8d, %eax
jl 0x71dc
movl %r8d, %edx
testl %r8d, %r8d
cmovel %eax, %edx
cmpl %esi, %ebp
movl %r13d, 0x40(%rbx)
movl %edx, 0x2c(%rbx)
cmovlel %r13d, %edx
movl %ebp, %eax
subl %edx, %eax
movl %eax, 0x24(%rbx)
jmp 0x71fe
cmpl $0x0, 0x40(%rbx)
je 0x71a8
movl 0x4c(%rsp), %esi
testl %ecx, %ecx
je 0x7255
movl %r12d, %eax
subl %esi, %eax
movl %eax, %ecx
negl %ecx
cmovsl %eax, %ecx
movl %ecx, %eax
subl 0x64(%rbx), %eax
cltd
idivl 0x5c(%rbx)
subl %edx, %ecx
movl 0x4c(%rbx), %edi
movl %ecx, %eax
cmpl %edi, %ecx
jg 0x7228
movl %edi, %eax
movl 0x54(%rbx), %edx
testl %edi, %edi
cmovel %ecx, %eax
movl %eax, %ecx
cmpl %edx, %eax
jl 0x7238
movl %edx, %ecx
testl %edx, %edx
cmovel %eax, %ecx
cmpl %esi, %r12d
movl %r13d, 0x44(%rbx)
movl %ecx, 0x30(%rbx)
cmovlel %r13d, %ecx
movl %r12d, %eax
subl %ecx, %eax
movl %eax, 0x28(%rbx)
jmp 0x725b
cmpl $0x0, 0x44(%rbx)
je 0x7206
movq (%r15), %rdi
xorl %esi, %esi
callq 0x3490
movq (%r15), %rdi
callq 0x34b0
movq %rbx, %rdi
callq 0x72b6
jmp 0x7153
movq %rbx, %rdi
callq 0x72b6
movq (%r15), %rdi
callq 0x33f0
movq (%r15), %rdi
xorl %esi, %esi
callq 0x33c0
movq %rbx, %rdi
callq 0x73c5
movq %rbx, %rdi
callq 0x5a8e
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq