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

Disassembly:
push 0xffffffffffffffff
push 0x576448
mov eax, dword fs:[0]
push eax
sub esp, 0x44
push ebx
push ebp
mov eax, dword [0x5e95e0]
xor eax, esp
push eax
lea eax, [esp + 0x50]
mov dword fs:[0], eax
mov eax, dword [esi + 0x78]
test eax, eax
mov ebp, esi
je 0x512fb9
mov edi, edi
mov ebp, eax
mov eax, dword [ebp + 0x78]
test eax, eax
jne 0x512fb0
mov ecx, dword [esi + 0x20]
lea eax, [esp + 0x30]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov edx, dword [ebp + 0x110]
push edx
push 1
push 0
lea ecx, [esp + 0x1c]
call fcn.005374b8
lea eax, [esp + 0x10]
push eax
mov ecx, edi
mov dword [esp + 0x5c], 0
call fcn.0053741e
push 0
push 0
lea ecx, [esp + 0x20]
push ecx
mov ecx, edi
mov ebx, eax
call fcn.00536d88
mov edx, dword [esp + 0x3c]
add edx, 0xffffffff
push edx
push 0
mov ecx, edi
call fcn.00536a70
mov eax, dword [esp + 0x3c]
mov ecx, dword [esp + 0x38]
add eax, 0xffffffff
add ecx, 0xffffffff
push eax
push ecx
mov ecx, edi
call fcn.00536a70
mov edx, dword [esp + 0x38]
push 0
add edx, 0xffffffff
push edx
mov ecx, edi
call fcn.00536a70
push 0
push 0
mov ecx, edi
call fcn.00536a70
push ebx
mov ecx, edi
call fcn.0053741e
lea ecx, [esp + 0x10]
call fcn.00537399
mov ecx, dword [esp + 0x34]
mov eax, dword [esp + 0x30]
mov edx, dword [esp + 0x38]
push 0xffffffffffffffff
mov dword [esp + 0x48], ecx
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0x40]
push 0xffffffffffffffff
lea ecx, [esp + 0x48]
push ecx
mov dword [esp + 0x54], edx
mov dword [esp + 0x58], eax
call dword [sym.imp.USER32.dll_InflateRect]
test edi, edi
jne 0x51308e
xor eax, eax
jmp 0x513091
mov eax, dword [edi + 4]
mov ecx, dword [ebp + 0x11c]
mov edx, dword [ebp + 0x118]
push eax
lea ebx, [esp + 0x44]
call fcn.00514790
add esp, 4
push 1
mov ecx, edi
call fcn.00536951
call fcn.00511ab0
mov eax, dword [0x5ec234]
xor ebx, ebx
cmp eax, ebx
jne 0x5130cf
push 0x11
call dword [sym.imp.GDI32.dll_GetStockObject]
cmp eax, ebx
je 0x5130e0
mov edx, dword [edi + 4]
push eax
push edx
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0xc], eax
jmp 0x5130e4
mov dword [esp + 0xc], ebx
mov eax, dword [esi + 0xd0]
mov edx, 2
add eax, edx
mov dword [esp + 0x28], eax
mov eax, dword [esi + 0x6c]
test eax, eax
mov dword [esp + 0x20], edx
mov dword [esp + 0x24], edx
mov dword [esp + 0x2c], edx
jle 0x513209
test ebx, ebx
jl 0x513247
cmp ebx, dword [esi + 0x6c]
jge 0x513247
mov eax, dword [esi + 0x68]
lea ecx, [ebx*4]
add eax, ecx
mov eax, dword [eax]
cmp dword [eax + 0x18], 0
mov ecx, 3
jne 0x51313c
mov ecx, dword [esi + 0xcc]
add edx, ecx
cmp edx, dword [esp + 0x3c]
mov dword [esp + 0x2c], edx
jle 0x51316d
mov eax, dword [esi + 0xd0]
mov edx, dword [esp + 0x20]
add edx, eax
add eax, edx
add ecx, 2
mov dword [esp + 0x20], edx
mov dword [esp + 0x24], 2
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], ecx
xor edx, edx
cmp dword [ebp + 0x12c], edx
je 0x5131b4
cmp esi, dword [ebp + 0x134]
jne 0x513187
cmp ebx, dword [ebp + 0x130]
je 0x5131b4
cmp esi, dword [ebp + 0x140]
jne 0x5131b4
cmp ebx, dword [ebp + 0x138]
jne 0x51319c
mov edx, 1
mov eax, dword [esi + 0x6c]
add eax, 0xffffffff
cmp ebx, eax
jne 0x5131b4
cmp dword [ebp + 0x13c], 0
je 0x5131b4
mov edx, 2
cmp ebx, dword [esi + 0x6c]
jge 0x513247
mov eax, dword [esi + 0x68]
lea ecx, [ebx*4]
add eax, ecx
mov ecx, dword [eax]
cmp dword [ecx + 0x18], 0
push edx
lea ecx, [esp + 0x24]
je 0x5131e0
push esi
mov edx, edi
call fcn.00513590
jmp 0x5131f5
xor edx, edx
cmp ebx, dword [esi + 0x84]
sete dl
push edx
push ebx
push edi
push ebp
push esi
call fcn.005132f0
mov edx, dword [esp + 0x2c]
add ebx, 1
cmp ebx, dword [esi + 0x6c]
mov dword [esp + 0x24], edx
jl 0x51310c
mov eax, dword [esp + 0xc]
test eax, eax
je 0x51321c
push eax
mov eax, dword [edi + 4]
push eax
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x58], 0xffffffff
lea ecx, [esp + 0x10]
mov dword [esp + 0x10], vtable.CGdiObject.0
call fcn.00537399
mov ecx, dword [esp + 0x50]
mov dword fs:[0], ecx
pop ecx
pop ebp
pop ebx
add esp, 0x50
ret
jmp fcn.00530cad