// File: /workspace/github_c_makefile_star2_O0/zenlinux[P]cwm/xevents.c
// Function: xev_handle_configurerequest
static void
xev_handle_configurerequest(XEvent *ee)
{
	XConfigureRequestEvent	*e = &ee->xconfigurerequest;
	struct client_ctx	*cc;
	struct screen_ctx	*sc;
	XWindowChanges		 wc;

	if ((cc = client_find(e->window)) != NULL) {
		sc = cc->sc;

		if (e->value_mask & CWWidth)
			cc->geom.w = e->width;
		if (e->value_mask & CWHeight)
			cc->geom.h = e->height;
		if (e->value_mask & CWX)
			cc->geom.x = e->x;
		if (e->value_mask & CWY)
			cc->geom.y = e->y;
		if (e->value_mask & CWBorderWidth)
			wc.border_width = e->border_width;

		if (cc->geom.x == 0 && cc->geom.w >= sc->view.w)
			cc->geom.x -= cc->bwidth;

		if (cc->geom.y == 0 && cc->geom.h >= sc->view.h)
			cc->geom.y -= cc->bwidth;

		wc.x = cc->geom.x;
		wc.y = cc->geom.y;
		wc.width = cc->geom.w;
		wc.height = cc->geom.h;
		wc.border_width = cc->bwidth;

		XConfigureWindow(X_Dpy, cc->win, e->value_mask, &wc);
		xu_configure(cc);
	} else {
		/* let it do what it wants, it'll be ours when we map it. */
		wc.x = e->x;
		wc.y = e->y;
		wc.width = e->width;
		wc.height = e->height;
		wc.border_width = e->border_width;
		wc.stack_mode = Above;
		e->value_mask &= ~CWStackMode;

		XConfigureWindow(X_Dpy, e->window, e->value_mask, &wc);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rdi
callq 0x6510
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
je 0xd389
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
andq $0x4, %rax
cmpq $0x0, %rax
je 0xd24b
movq -0x10(%rbp), %rax
movl 0x38(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x5c(%rax)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
andq $0x8, %rax
cmpq $0x0, %rax
je 0xd26b
movq -0x10(%rbp), %rax
movl 0x3c(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x60(%rax)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xd28b
movq -0x10(%rbp), %rax
movl 0x30(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x54(%rax)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
andq $0x2, %rax
cmpq $0x0, %rax
je 0xd2ab
movq -0x10(%rbp), %rax
movl 0x34(%rax), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x58(%rax)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
andq $0x10, %rax
cmpq $0x0, %rax
je 0xd2c7
movq -0x10(%rbp), %rax
movl 0x40(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x54(%rax)
jne 0xd2f7
movq -0x18(%rbp), %rax
movl 0x5c(%rax), %eax
movq -0x20(%rbp), %rcx
cmpl 0xac(%rcx), %eax
jl 0xd2f7
movq -0x18(%rbp), %rax
movl 0x50(%rax), %edx
movq -0x18(%rbp), %rax
movl 0x54(%rax), %ecx
subl %edx, %ecx
movl %ecx, 0x54(%rax)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x58(%rax)
jne 0xd327
movq -0x18(%rbp), %rax
movl 0x60(%rax), %eax
movq -0x20(%rbp), %rcx
cmpl 0xb0(%rcx), %eax
jl 0xd327
movq -0x18(%rbp), %rax
movl 0x50(%rax), %edx
movq -0x18(%rbp), %rax
movl 0x58(%rax), %ecx
subl %edx, %ecx
movl %ecx, 0x58(%rax)
movq -0x18(%rbp), %rax
movl 0x54(%rax), %eax
movl %eax, -0x48(%rbp)
movq -0x18(%rbp), %rax
movl 0x58(%rax), %eax
movl %eax, -0x44(%rbp)
movq -0x18(%rbp), %rax
movl 0x5c(%rax), %eax
movl %eax, -0x40(%rbp)
movq -0x18(%rbp), %rax
movl 0x60(%rax), %eax
movl %eax, -0x3c(%rbp)
movq -0x18(%rbp), %rax
movl 0x50(%rax), %eax
movl %eax, -0x38(%rbp)
leaq 0xf448(%rip), %rax      # 0x1c7a8
movq (%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x38(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
movl %eax, %edx
leaq -0x48(%rbp), %rcx
callq 0x50e0
movq -0x18(%rbp), %rdi
callq 0xae30
jmp 0xd3f7
movq -0x10(%rbp), %rax
movl 0x30(%rax), %eax
movl %eax, -0x48(%rbp)
movq -0x10(%rbp), %rax
movl 0x34(%rax), %eax
movl %eax, -0x44(%rbp)
movq -0x10(%rbp), %rax
movl 0x38(%rax), %eax
movl %eax, -0x40(%rbp)
movq -0x10(%rbp), %rax
movl 0x3c(%rax), %eax
movl %eax, -0x3c(%rbp)
movq -0x10(%rbp), %rax
movl 0x40(%rax), %eax
movl %eax, -0x38(%rbp)
movl $0x0, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rcx
andq $-0x41, %rcx
movq %rcx, 0x58(%rax)
leaq 0xf3cf(%rip), %rax      # 0x1c7a8
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
movl %eax, %edx
leaq -0x48(%rbp), %rcx
callq 0x50e0
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax)