Function at 0x409830
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x58
push ebx
push esi
push edi
xor esi, esi
push ebp
push eax
call fcn.00406810
mov di, word [esp + 0x72]
mov ecx, dword [esp + 0x8c]
lea edx, [esp + 0x78]
add esp, 4
test eax, eax
mov eax, dword [esp + 0x84]
push ecx
push eax
push edx
je 0x409872
call dword [sym.imp.USER32.dll_PtInRect]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x58
ret
mov ebx, dword [sym.imp.USER32.dll_PtInRect]
call ebx
test eax, eax
je 0x409a99
mov eax, dword [esp + 0x6c]
push eax
call fcn.00407190
add esp, 4
mov ebp, eax
test ebp, ebp
jne 0x4098a2
mov eax, 1
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x58
ret
push ebp
call fcn.00409130
add esp, 4
test eax, eax
jne 0x4098b9
mov esi, 1
jmp 0x409a7f
mov eax, dword [esp + 0x74]
mov ecx, dword [esp + 0x78]
lea edx, [esp + 0x24]
sub dword [esp + 0x84], eax
sub dword [esp + 0x88], ecx
push edx
push ebp
call fcn.004074c0
lea ecx, [esp + 0x4c]
lea edx, [esp + 0x6c]
lea eax, [esp + 0x54]
add esp, 8
push 1
push ecx
lea ecx, [esp + 0x18]
push edx
lea edx, [esp + 0x6c]
push eax
lea eax, [esp + 0x6c]
push ecx
lea ecx, [esp + 0x44]
push edx
lea edx, [esp + 0x44]
push eax
lea eax, [esp + 0x2e]
push ecx
mov ecx, dword [esp + 0x90]
push edx
push eax
push ecx
push ebp
call fcn.00407570
add esp, 0x30
cmp dword [esp + 0x2c], 0
je 0x40996a
mov eax, dword [esp + 0x54]
sub eax, dword [esp + 0x4c]
test eax, eax
jle 0x40996a
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x24]
lea edx, [esp + 0x4c]
push eax
push ecx
push edx
call dword [sym.imp.USER32.dll_OffsetRect]
mov edx, dword [esp + 0x84]
mov ecx, dword [esp + 0x88]
lea eax, [esp + 0x4c]
push ecx
push edx
push eax
call ebx
test eax, eax
je 0x40996a
mov esi, 1
jmp 0x409a7f
xor ecx, ecx
cmp dword [esp + 0x30], ecx
je 0x409a7f
mov eax, dword [esp + 0x24]
add eax, dword [esp + 0x44]
sub dword [esp + 0x84], eax
mov eax, dword [esp + 0x28]
add eax, dword [esp + 0x48]
sub dword [esp + 0x88], eax
test byte [ebp], 0x40
jne 0x4099d0
mov edx, dword [esp + 0x84]
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], ecx
movsx eax, word [ebp + 2]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x88]
movsx ecx, word [ebp + 4]
mov dword [esp + 0x20], ecx
push eax
lea ecx, [esp + 0x18]
push edx
push ecx
call ebx
mov esi, eax
jmp 0x409a7f
movsx eax, word [ebp + 4]
movzx ebx, di
shl ebx, 0x10
inc eax
movsx ecx, word [esp + 0x12]
imul eax, ecx
add dword [esp + 0x88], eax
xor eax, eax
mov ax, word [ebp + 6]
or eax, ebx
push eax
call fcn.004ac870
mov dword [esp + 0x18], eax
add esp, 4
test eax, eax
je 0x409a7f
movsx eax, di
mov ecx, dword [esp + 0x88]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x84]
push 1
mov dword [esp + 0x44], ecx
push 1
mov dword [esp + 0x40], ecx
mov dword [esp + 0x44], eax
mov dword [esp + 0x3c], eax
lea eax, [esp + 0x3c]
push eax
call dword [sym.imp.USER32.dll_InflateRect]
lea ecx, [esp + 0x34]
push 1
mov eax, dword [esp + 0x88]
push ecx
mov edx, dword [esp + 0x90]
mov esi, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
push edx
push eax
push ecx
push esi
call fcn.004a61a0
add esp, 0x18
mov esi, eax
xor eax, eax
push 0
mov ax, word [ebp + 6]
sub esi, 0xd
or eax, ebx
push eax
call fcn.004acd20
add esp, 8
cmp esi, 1
sbb esi, esi
neg esi
mov eax, dword [esp + 0x6c]
push 0
push ebp
push eax
call fcn.004071f0
add esp, 0xc
mov eax, esi
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x58
ret
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x58
ret