Function at 0x408670
Capabilities:
Hide graphical window

Disassembly:
sub esp, 0x34
lea eax, [esp + 4]
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov edi, dword [sym.imp.USER32.dll_GetClientRect]
mov ecx, dword [esi + 0x178]
push eax
push ecx
call edi
mov ebx, dword [esp + 0x1c]
mov edx, dword [esp + 0x14]
mov ebp, dword [esp + 0x20]
mov ecx, dword [esp + 0x18]
sub ebx, edx
mov edx, dword [esi + 0x178]
push 0
push 0x9f
push 0
push edx
sub ebp, ecx
call dword [sym.imp.USER32.dll_GetSystemMenu]
push eax
call dword [sym.imp.USER32.dll_GetMenuState]
cmp eax, 8
jne 0x408713
mov ecx, dword [esi + 0x17c]
lea eax, [esp + 0x24]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetWindowRect]
mov edi, dword [esp + 0x30]
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x14]
mov ecx, dword [esi + 0x17c]
sub edi, edx
mov edx, dword [esp + 0x18]
sub edi, 3
push 0x40
push edi
push ebx
push edx
push eax
push 0
push ecx
call dword [sym.imp.USER32.dll_SetWindowPos]
mov eax, dword [esp + 0x18]
sub ebp, edi
add eax, edi
mov edi, dword [sym.imp.USER32.dll_GetClientRect]
mov dword [esp + 0x18], eax
jmp 0x408722
mov edx, dword [esi + 0x17c]
push 0
push edx
call dword [sym.imp.USER32.dll_ShowWindow]
mov edx, dword [esp + 0x18]
lea eax, [ebp + 2]
push 0x40
push eax
mov eax, dword [esp + 0x1c]
lea ecx, [ebx + 2]
dec edx
push ecx
mov ecx, dword [esi + 0x180]
dec eax
push edx
push eax
push 0
push ecx
call dword [sym.imp.USER32.dll_SetWindowPos]
mov al, byte [esi + 0x407d]
test al, al
jne 0x408838
mov ecx, esi
call fcn.0040e2f0
test al, al
je 0x408785
mov edx, dword [esi + 0x180]
mov edi, dword [sym.imp.USER32.dll_ShowScrollBar]
push 0
push 0
push edx
call edi
mov eax, dword [esi + 0x180]
push 0
push 1
push eax
call edi
jmp 0x40898b
mov eax, dword [esi + 0x4778]
mov edx, dword [esi + 0x180]
xor ecx, ecx
cmp ebp, eax
mov ebp, dword [sym.imp.USER32.dll_ShowScrollBar]
setl cl
push ecx
push 1
push edx
call ebp
mov ecx, dword [esi + 0x4774]
xor eax, eax
cmp ebx, ecx
mov ecx, dword [esi + 0x180]
setl al
push eax
push 0
push ecx
call ebp
mov eax, dword [esi + 0x180]
lea edx, [esp + 0x14]
push edx
push eax
call edi
mov ebx, dword [esp + 0x1c]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x18]
sub ebx, eax
mov eax, dword [esi + 0x4778]
sub ecx, edx
xor edx, edx
cmp ecx, eax
mov eax, dword [esi + 0x180]
setl dl
push edx
push 1
push eax
call ebp
mov eax, dword [esi + 0x4774]
mov edx, dword [esi + 0x180]
xor ecx, ecx
cmp ebx, eax
setl cl
push ecx
push 0
push edx
call ebp
mov ecx, dword [esi + 0x180]
lea eax, [esp + 0x14]
push eax
push ecx
call edi
mov ebx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x14]
mov ebp, dword [esp + 0x20]
mov eax, dword [esp + 0x18]
sub ebx, ecx
sub ebp, eax
jmp 0x40898b
mov edx, dword [esi + 0x178]
push edx
call dword [sym.imp.USER32.dll_IsIconic]
test eax, eax
jne 0x40898b
mov ebx, dword [sym.imp.USER32.dll_ShowScrollBar]
push eax
push eax
mov eax, dword [esi + 0x180]
push eax
call ebx
mov ecx, dword [esi + 0x180]
push 0
push 1
push ecx
call ebx
mov eax, dword [esi + 0x180]
lea edx, [esp + 0x14]
push edx
push eax
call edi
mov ebx, dword [esp + 0x1c]
mov edx, dword [esp + 0x14]
mov ebp, dword [esp + 0x20]
mov ecx, dword [esp + 0x18]
sub ebx, edx
sub ebp, ecx
cmp ebx, 1
jl 0x408b4f
cmp ebp, 1
jl 0x408b4f
xor eax, eax
mov ax, word [esi + 0x471a]
lea eax, [eax + eax*4]
lea ecx, [eax + eax*4]
shl ecx, 2
mov eax, ecx
cdq
idiv ebp
mov edi, eax
xor eax, eax
mov ax, word [esi + 0x4718]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
shl eax, 2
mov dword [esp + 0x10], eax
cdq
idiv ebx
cmp eax, edi
jle 0x4088d7
mov edi, eax
lea eax, [ecx + edi - 1]
mov ecx, dword [esp + 0x10]
cdq
idiv edi
push eax
lea eax, [ecx + edi - 1]
cdq
idiv edi
lea edx, [esp + 0x28]
push eax
push 0
push 0
push edx
call dword [sym.imp.USER32.dll_SetRect]
mov eax, dword [esp + 0x2c]
mov edx, dword [esp + 0x24]
sub eax, edx
cmp eax, ebx
jg 0x408916
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x28]
sub ecx, edx
cmp ecx, ebp
jle 0x408950
xor eax, eax
inc edi
mov ax, word [esi + 0x471a]
lea ecx, [esp + 0x24]
lea eax, [eax + eax*4]
lea edx, [eax + eax*4]
lea eax, [edi + edx*4 - 1]
cdq
idiv edi
push eax
xor eax, eax
mov ax, word [esi + 0x4718]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
lea eax, [edi + eax*4 - 1]
cdq
idiv edi
push eax
push 0
push 0
push ecx
jmp 0x4088f4
lea ecx, [esi + 0x3e44]
mov dword [esi + 0x4080], 0x64
mov dword [esi + 0x4084], edi
call fcn.0041ce40
mov edx, dword [esp + 0x2c]
mov edi, dword [esp + 0x24]
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x28]
sub edx, edi
sub eax, ecx
mov dword [esi + 0x4774], edx
mov dword [esi + 0x4778], eax
mov ecx, dword [esi + 0x4774]
cmp ebx, ecx
jle 0x4089a2
mov eax, ebx
sub eax, ecx
cdq
sub eax, edx
mov edi, eax
sar edi, 1
jmp 0x4089a6
mov edi, dword [esp + 0x14]
mov ecx, dword [esi + 0x4778]
cmp ebp, ecx
jle 0x4089bb
mov eax, ebp
sub eax, ecx
cdq
sub eax, edx
sar eax, 1
jmp 0x4089bf
mov eax, dword [esp + 0x18]
cmp ebp, ecx
mov edx, ebp
jl 0x4089c7
mov edx, ecx
mov ecx, dword [esi + 0x4774]
cmp ebx, ecx
jge 0x4089d3
mov ecx, ebx
push 0x40
push edx
push ecx
mov ecx, dword [esi + 0x170]
push eax
push edi
push 0
push ecx
call dword [sym.imp.USER32.dll_SetWindowPos]
mov eax, dword [esi + 0x4774]
cmp ebx, eax
jl 0x4089f4
mov ebx, eax
mov edi, dword [esi + 0x4778]
mov dword [esi + 0x476c], ebx
cmp ebp, edi
jl 0x408a06
mov ebp, edi
mov cl, byte [esi + 0x407d]
mov dword [esi + 0x4770], ebp
test cl, cl
mov dword [esi + 0x4760], eax
mov dword [esi + 0x4768], edi
jne 0x408ad0
xor ecx, ecx
mov edx, eax
test ebx, ebx
setle cl
dec ecx
and ecx, ebx
sub edx, ecx
mov ecx, dword [esi + 0x475c]
cmp ecx, edx
jl 0x408a4c
xor edx, edx
mov ecx, eax
test ebx, ebx
setle dl
dec edx
and edx, ebx
sub ecx, edx
test ecx, ecx
jge 0x408a54
xor ebx, ebx
jmp 0x408a7e
xor ecx, ecx
mov edx, eax
test ebx, ebx
setle cl
dec ecx
and ecx, ebx
sub edx, ecx
mov ecx, dword [esi + 0x475c]
cmp ecx, edx
jge 0x408a70
mov ebx, ecx
jmp 0x408a7e
xor ecx, ecx
test ebx, ebx
setle cl
dec ecx
and ecx, ebx
sub eax, ecx
mov ebx, eax
xor eax, eax
mov ecx, dword [esi + 0x4764]
test ebp, ebp
setle al
dec eax
mov edx, edi
and eax, ebp
sub edx, eax
cmp ecx, edx
jge 0x408a9a
mov eax, ecx
jmp 0x408aa8
xor edx, edx
mov eax, edi
test ebp, ebp
setle dl
dec edx
and edx, ebp
sub eax, edx
test eax, eax
jl 0x408ad2
xor eax, eax
mov edx, edi
test ebp, ebp
setle al
dec eax
and eax, ebp
sub edx, eax
cmp ecx, edx
jge 0x408ac2
mov edi, ecx
jmp 0x408ad4
xor eax, eax
test ebp, ebp
setle al
dec eax
and eax, ebp
sub edi, eax
jmp 0x408ad4
xor ebx, ebx
xor edi, edi
mov ecx, dword [esi + 0x170]
lea eax, [esp + 0x34]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [esi + 0x4764]
mov ecx, dword [esi + 0x475c]
push 2
push 0
lea edx, [esp + 0x3c]
push 0
push edx
mov edx, dword [esi + 0x170]
sub eax, edi
push 0
sub ecx, ebx
push eax
push ecx
push edx
call dword [sym.imp.USER32.dll_ScrollWindowEx]
mov al, byte [esi + 0x407d]
mov dword [esi + 0x475c], ebx
test al, al
mov dword [esi + 0x4764], edi
jne 0x408b31
mov ecx, esi
call fcn.0040b0c0
jmp 0x408b42
mov eax, dword [esi + 0x170]
push 0
push 0
push eax
call dword [sym.imp.USER32.dll_InvalidateRect]
mov ecx, dword [esi + 0x170]
push ecx
call dword [sym.imp.USER32.dll_UpdateWindow]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x34
ret