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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x8c
mov eax, dword [0x6510e8]
xor eax, esp
mov dword [esp + 0x88], eax
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, ecx
cmp byte [esi + 0x15], 0
je 0x515ca0
mov eax, dword [edi + 0x70]
cmp eax, dword [edi + 0x78]
jne 0x515ca0
mov eax, dword [edi + 0x74]
cmp eax, dword [edi + 0x7c]
jne 0x515ca0
mov eax, dword [edi + 0x80]
mov ecx, dword [edi + 0x84]
mov dword [edi + 0x78], eax
mov dword [edi + 0x7c], ecx
mov dword [edi + 0x70], eax
mov dword [edi + 0x74], ecx
mov eax, dword [edi]
mov ebx, dword [edi + 0x80]
mov eax, dword [eax + 0x174]
mov eax, dword [eax]
mov ecx, dword [eax + 0x40]
mov eax, dword [eax + 0x44]
mov dword [esp + 0x1c], eax
mov eax, dword [edi + 0x84]
push eax
push ebx
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x2c]
push 0
mov dword [esp + 0x48], ecx
mov ecx, edi
push eax
call fcn.00516e50
mov eax, dword [esp + 0x24]
mov edx, dword [esp + 0x28]
mov dword [esp + 0x18], eax
mov dword [esp + 0x34], eax
movzx eax, word [esi + 0x10]
mov dword [esp + 0x2c], eax
mov eax, dword [edi + 8]
mov dword [esp + 0x10], edx
mov dword [esp + 0x38], edx
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
test eax, eax
je 0x515d40
lea ecx, [esp + 0x58]
push ecx
push dword [eax]
call dword [sym.imp.GDI32.dll_GetTextMetricsW]
mov eax, dword [edi]
mov edx, dword [esp + 0x60]
add edx, dword [esp + 0x5c]
push edx
mov eax, dword [eax + 0x174]
mov dword [esp + 0x24], edx
mov eax, dword [eax]
mov ecx, dword [eax + 0x48]
mov eax, dword [ecx + 0xd0]
add ecx, 0xd0
call dword [eax + 0x20]
mov edx, dword [esp + 0x28]
jmp 0x515d48
mov dword [esp + 0x20], 0
mov esi, dword [edi]
mov ecx, dword [edi + 0x84]
mov eax, dword [esi + 0x94]
mov dword [esp + 0x30], eax
lea eax, [esi + 0x84]
cmp ecx, dword [esi + 0x94]
jae 0x515d8c
mov ecx, dword [esi + 0x90]
add ecx, dword [edi + 0x84]
mov dword [esp + 0x50], eax
mov eax, dword [esi + 0x8c]
dec eax
and ecx, eax
mov eax, dword [esi + 0x88]
mov ecx, dword [eax + ecx*4]
jmp 0x515d92
lea ecx, [esi + 0xb8]
mov eax, dword [esp + 0x2c]
mov ecx, dword [ecx + 0x10]
movzx eax, ax
add eax, 0xffffffdf
mov dword [esp + 0x50], eax
cmp eax, 7
ja case.default.0x515dac
jmp dword [eax*4 + 0x516110]
cmp byte [edi + 0x65], 0
je 0x515ddd
mov eax, dword [edi + 0x70]
cmp eax, dword [edi + 0x78]
jne 0x515dc9
mov eax, dword [edi + 0x74]
cmp eax, dword [edi + 0x7c]
je 0x515ddd
mov eax, dword [ebp + 8]
cmp byte [eax + 0x15], 0
jne 0x515ddd
mov ebx, dword [edi + 0x70]
mov edx, dword [edi + 0x74]
jmp 0x516051
mov edx, dword [esp + 0x14]
test ebx, ebx
je 0x515deb
dec ebx
jmp 0x51604e
test edx, edx
je 0x51604e
dec edx
cmp edx, dword [esi + 0x94]
jae 0x515e1e
mov ecx, dword [esi + 0x90]
mov eax, dword [esi + 0x8c]
add ecx, edx
dec eax
and ecx, eax
mov eax, dword [esi + 0x88]
mov ebx, dword [eax + ecx*4]
mov ebx, dword [ebx + 0x10]
jmp 0x51604e
lea ebx, [esi + 0xb8]
mov ebx, dword [ebx + 0x10]
jmp 0x51604e
cmp byte [edi + 0x65], 0
je 0x515e56
mov eax, dword [edi + 0x70]
cmp eax, dword [edi + 0x78]
jne 0x515e42
mov eax, dword [edi + 0x74]
cmp eax, dword [edi + 0x7c]
je 0x515e56
mov eax, dword [ebp + 8]
cmp byte [eax + 0x15], 0
jne 0x515e56
mov ebx, dword [edi + 0x78]
mov edx, dword [edi + 0x7c]
jmp 0x516051
mov edx, dword [esp + 0x14]
cmp ebx, ecx
jae 0x515e64
inc ebx
jmp 0x51604e
mov eax, dword [esp + 0x30]
dec eax
cmp edx, eax
mov eax, dword [ebp + 8]
je 0x516051
inc edx
xor ebx, ebx
jmp 0x516051
sub edx, dword [esp + 0x20]
jmp 0x515ff0
add edx, dword [esp + 0x20]
jmp 0x515ff0
mov eax, dword [ebp + 8]
xor ebx, ebx
cmp byte [eax + 0x14], bl
je 0x515f06
xor edx, edx
jmp 0x516051
mov eax, dword [ebp + 8]
cmp byte [eax + 0x14], 0
je 0x515f04
mov eax, dword [esi + 0x94]
xor ecx, ecx
dec eax
mov edx, eax
imul edx, dword [esp + 0x20]
cmp ecx, eax
sbb ebx, ebx
and ebx, eax
mov dword [esp + 0x10], edx
cmp ebx, dword [esi + 0x94]
jae 0x515ef6
mov ecx, dword [esi + 0x90]
lea eax, [esi + 0x84]
mov dword [esp + 0x24], eax
add ecx, ebx
mov eax, dword [esi + 0x8c]
dec eax
and ecx, eax
mov eax, dword [esi + 0x88]
mov ebx, dword [eax + ecx*4]
mov ebx, dword [ebx + 0x10]
jmp 0x515ff4
lea ebx, [esi + 0xb8]
mov ebx, dword [ebx + 0x10]
jmp 0x515ff4
mov ebx, ecx
mov edx, dword [esp + 0x14]
jmp 0x516051
mov eax, dword [esp + 0x1c]
test eax, eax
jle case.default.0x515dac
mov ecx, dword [esi + 0x174]
sub edx, eax
mov dword [esp + 0x10], edx
mov eax, dword [ecx]
add eax, 0x18
push eax
lea eax, [esp + 0x44]
push eax
call fcn.005332f0
mov edx, dword [esp + 0x1c]
mov eax, edx
cmp dword [esp + 0x4c], edx
cmovl eax, dword [esp + 0x4c]
sub edx, eax
mov eax, dword [esp + 0x24]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x10]
add edx, dword [esp + 0x1c]
mov dword [esp + 0x18], eax
jmp 0x515ff0
mov eax, dword [esi + 0x174]
mov dword [esp + 0x2c], eax
mov esi, dword [eax]
lea ecx, [esi + 0x18]
push ecx
mov dword [esp + 0x24], ecx
lea ecx, [esp + 0x44]
push ecx
mov ecx, eax
call fcn.005332f0
mov eax, dword [esi + 0x1c]
cmp eax, dword [esp + 0x4c]
jbe case.default.0x515dac
mov eax, dword [esp + 0x28]
sub eax, dword [esp + 0x1c]
push dword [esp + 0x20]
mov ecx, dword [esp + 0x30]
mov dword [esp + 0x14], eax
lea eax, [esp + 0x44]
push eax
call fcn.005332f0
mov eax, dword [esi + 0x1c]
sub eax, dword [esp + 0x4c]
push dword [esp + 0x20]
mov ecx, dword [esp + 0x30]
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x44]
push eax
call fcn.005332f0
mov eax, dword [esp + 0x4c]
add eax, dword [esp + 0x1c]
cmp dword [esp + 0x18], eax
mov ecx, eax
mov edx, dword [esp + 0x24]
cmovl ecx, dword [esp + 0x18]
mov esi, dword [edi]
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x10]
mov dword [esp + 0x1c], ecx
add edx, ecx
mov dword [esp + 0x10], edx
mov eax, dword [esp + 0x34]
cmp dword [esp + 0x18], eax
jne 0x516004
cmp edx, dword [esp + 0x38]
je case.default.0x515dac
mov ecx, dword [esi + 0x174]
mov edx, dword [esp + 0x3c]
mov eax, dword [ecx]
sub edx, dword [eax + 0x40]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x1c]
sub edx, dword [eax + 0x44]
lea eax, [esp + 0x24]
push eax
mov dword [esp + 0x2c], edx
call fcn.00533390
mov eax, dword [esp + 0x10]
mov ecx, edi
push eax
push dword [esp + 0x1c]
lea eax, [esp + 0x2c]
push 0
push eax
call fcn.005174c0
mov ebx, dword [eax]
mov edx, dword [eax + 4]
jmp 0x51604e
mov edx, dword [esp + 0x14]
mov eax, dword [ebp + 8]
cmp ebx, dword [edi + 0x80]
jne 0x516065
cmp edx, dword [edi + 0x84]
je 0x5160f9
cmp byte [eax + 0x15], 0
je 0x516082
mov eax, dword [esp + 0x50]
cmp eax, 7
ja case.default.0x51607b
movzx eax, byte [eax + 0x516134]
jmp dword [eax*4 + 0x516130]
mov dword [edi + 0x70], ebx
mov dword [edi + 0x74], edx
mov dword [edi + 0x7c], edx
mov dword [edi + 0x78], ebx
mov eax, dword [edi]
mov ecx, edi
mov dword [edi + 0x80], ebx
mov dword [edi + 0x84], edx
mov dword [eax + 0xd8], 1
call fcn.00519ca0
mov eax, dword [edi]
mov esi, dword [eax + 0x174]
mov eax, dword [esi]
mov byte [eax + 0x3c], 1
mov edx, dword [esi]
mov ecx, dword [edx + 0x48]
push dword [edx + 0x40]
add ecx, 0x68
mov eax, dword [ecx]
call dword [eax + 0x18]
mov edx, dword [esi]
mov ecx, dword [edx + 0x48]
push dword [edx + 0x44]
add ecx, 0xd0
mov eax, dword [ecx]
call dword [eax + 0x18]
mov eax, dword [esi]
mov ecx, edi
mov byte [eax + 0x3c], 1
push dword [edi + 0x84]
push dword [edi + 0x80]
push 0
call fcn.00513a50
mov ecx, dword [esp + 0x94]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00581335
mov esp, ebp
pop ebp
ret 4