Function at 0x502a00
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov eax, dword [0x5ac004]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, ecx
push edi
mov eax, dword [esi + 0x3c]
mov ecx, dword [esi + 0x48]
mov edi, dword [esi + 0x44]
sub ecx, dword [esi + 0x4c]
sub edi, dword [esi + 0x64]
mov ebx, dword [esi + 0xac]
mov dword [ebp - 0x30], eax
mov eax, dword [esi + 0x40]
mov dword [ebp - 0x2c], eax
mov eax, dword [esi + 0xd0]
mov dword [ebp - 0x34], ecx
mov eax, dword [eax]
imul eax, dword [esi + 0x50]
mov dword [ebp - 0x38], eax
cmp eax, ecx
jle 0x502a4c
sub edi, dword [esi + 0x54]
cmp ebx, edi
jle 0x502a56
sub ecx, dword [esi + 0x58]
mov dword [ebp - 0x34], ecx
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0x1c
push eax
push 2
push dword [esi + 0x10]
mov dword [ebp - 0x1c], 4
call dword [sym.imp.USER32.dll_GetScrollInfo]
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x3c], eax
mov eax, dword [esi + 0xd0]
mov dword [ebp - 0x1c], 3
mov dword [ebp - 0x18], 0
mov eax, dword [eax]
test eax, eax
je 0x502a99
dec eax
mov dword [ebp - 0x14], eax
jmp 0x502aa0
mov dword [ebp - 0x14], 0
mov eax, dword [ebp - 0x34]
cdq
idiv dword [esi + 0x50]
push 1
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x20]
push eax
push 2
push dword [esi + 0x10]
call dword [sym.imp.USER32.dll_SetScrollInfo]
lea eax, [ebp - 0x20]
mov dword [ebp - 0x1c], 4
push eax
push 2
push dword [esi + 0x10]
call dword [sym.imp.USER32.dll_GetScrollInfo]
mov eax, dword [ebp - 0xc]
mov ecx, eax
sub ecx, dword [ebp - 0x3c]
mov dword [esi + 0x5c], eax
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x3c], ecx
cmp eax, dword [ebp - 0x34]
jle 0x502afc
test eax, eax
je 0x502afc
push 5
push dword [esi + 0x10]
call dword [sym.imp.USER32.dll_ShowWindow]
or dword [esi + 0x20], 4
jmp 0x502b0b
push 0
push dword [esi + 0x10]
call dword [sym.imp.USER32.dll_ShowWindow]
and dword [esi + 0x20], 0xfffffffb
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0x1c
push eax
push 2
push dword [esi + 0x14]
mov dword [ebp - 0x1c], 4
call dword [sym.imp.USER32.dll_GetScrollInfo]
mov eax, dword ds:[ebp - 0xc]
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x1c], 3
mov dword [ebp - 0x18], 0
test ebx, ebx
je 0x502b4c
lea eax, [ebx - 1]
mov dword [ebp - 0x14], eax
jmp 0x502b53
mov dword [ebp - 0x14], 0
push 1
lea eax, [ebp - 0x20]
mov dword [ebp - 0x10], edi
push eax
push 2
push dword [esi + 0x14]
call dword [sym.imp.USER32.dll_SetScrollInfo]
lea eax, [ebp - 0x20]
mov dword [ebp - 0x1c], 4
push eax
push 2
push dword [esi + 0x14]
call dword [sym.imp.USER32.dll_GetScrollInfo]
mov eax, dword [ebp - 0xc]
mov ecx, eax
sub ecx, dword [ebp - 0x38]
mov dword [esi + 0x60], eax
mov eax, dword [esi + 0x20]
shr eax, 3
and eax, 1
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x38], eax
cmp ebx, edi
jle 0x502bb0
test ebx, ebx
je 0x502bb0
push 5
push dword [esi + 0x14]
call dword [sym.imp.USER32.dll_ShowWindow]
or dword [esi + 0x20], 8
jmp 0x502bbf
push 0
push dword [esi + 0x14]
call dword [sym.imp.USER32.dll_ShowWindow]
and dword [esi + 0x20], 0xfffffff7
mov ecx, dword [esi + 0x20]
mov eax, ecx
shr eax, 3
and eax, 1
cmp eax, dword [ebp - 0x38]
je 0x502bfd
and ecx, 0x60
cmp cl, 0x60
jne 0x502bfd
mov ecx, dword [esi + 0x64]
mov eax, dword [esi + 0x4c]
mov dword [ebp - 0x2c], eax
push 0
lea eax, [ecx + 1]
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x28], eax
mov eax, dword [esi + 0x48]
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x30]
push eax
push dword [esi]
call dword [sym.imp.USER32.dll_InvalidateRect]
mov edx, dword [ebp - 0x3c]
mov eax, dword [ebp - 0x34]
test edx, edx
jne 0x502c0b
test eax, eax
je 0x502c13
push eax
mov ecx, esi
call fcn.00502da0
mov eax, dword [esi + 0x20]
xor edx, edx
and eax, 0xc
mov ecx, 5
cmp al, 0xc
cmovne ecx, edx
push ecx
push dword [esi + 0x18]
call dword [sym.imp.USER32.dll_ShowWindow]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0051e068
mov esp, ebp
pop ebp
ret