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

Disassembly:
push 0xffffffffffffffff
push 0x5c96d8
mov eax, dword fs:[0]
push eax
sub esp, 0x2b0
push ebx
push ebp
push esi
push edi
mov eax, dword [0x67ff88]
xor eax, esp
push eax
lea eax, [esp + 0x2c4]
mov dword fs:[0], eax
mov esi, ecx
mov ebx, dword [esp + 0x2d4]
mov ebp, dword [esp + 0x2d8]
mov edi, dword [esp + 0x2dc]
mov dword [esp + 0x14], 0
cmp ebx, 0x100
ja 0x513e5d
je case.0x513e85.260
lea eax, [ebx - 1]
cmp eax, 0x86
ja case.0x514218.784
movzx eax, byte [eax + 0x514308]
jmp dword [eax*4 + 0x514298]
lea ecx, [esp + 0x1c]
push ecx
push edi
mov ecx, esi
call fcn.0050f500
mov bl, al
test bl, bl
je 0x51425e
xor edx, edx
cmp byte [esp + 0x1c], dl
setne dl
dec edx
mov dword [esp + 0x14], edx
jmp 0x51425a
call fcn.0050cf80
jmp case.0x514218.784
push ebp
mov eax, edi
shr eax, 0x10
movzx ecx, di
push eax
push ecx
mov ecx, esi
call fcn.005106b0
jmp 0x514258
mov edx, edi
shr edx, 0x10
movsx eax, dx
movsx ecx, di
push eax
push ecx
mov ecx, esi
call fcn.00510510
jmp 0x514258
mov eax, dword [0x68cc7c]
mov edx, dword [eax]
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], edx
call fcn.00517370
mov edx, dword [esp + 0x1c]
push eax
test ebp, ebp
setne al
movzx ecx, al
mov eax, dword [edx + 0xbc]
push ecx
mov ecx, dword [esp + 0x20]
call eax
jmp case.0x514218.784
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x20]
push edx
lea eax, [esp + 0x20]
push eax
push edi
push ebp
mov ecx, esi
call fcn.0050ce90
cmp word [esp + 0x1c], 0
mov ecx, dword [esp + 0x20]
push ecx
movzx ecx, word [esp + 0x1c]
setne dl
movzx eax, dl
push eax
push ecx
mov ecx, esi
call fcn.0050f530
jmp 0x514258
push ebp
call fcn.0050f5e0
jmp 0x514258
push ebp
call fcn.0050f720
jmp 0x514258
test ebp, ebp
je 0x5138e5
push ebp
push esi
lea ecx, [esp + 0x1c4]
call fcn.00516e10
mov ecx, esi
mov dword [esp + 0x2cc], 0
call fcn.00513600
lea ecx, [esp + 0x1bc]
mov bl, al
mov dword [esp + 0x2cc], 0xffffffff
call fcn.00516ac0
jmp 0x51425a
call fcn.00513600
jmp 0x514258
mov dword [esp + 0x14], 1
jmp 0x514278
test ebp, ebp
setne dl
movzx eax, dl
push edi
push eax
call fcn.0050f870
jmp 0x514258
lea ecx, [esp + 0x14]
push ecx
push edi
push ebp
mov ecx, esi
call fcn.0050f300
jmp 0x514258
cmp edi, 3
jne case.0x514218.784
mov dword [esp + 0x14], 2
jmp 0x514278
mov edx, dword [esi]
push edi
push ebp
cmp ebx, 0x2b
jne 0x51394a
mov eax, dword [edx + 0x27c]
jmp 0x513950
mov eax, dword [edx + 0x280]
call eax
mov bl, al
test bl, bl
je 0x51425e
mov dword [esp + 0x14], 1
jmp 0x51425a
cmp dword [esi + 0x118], 0
je 0x513984
mov ecx, dword [esi + 0xcc]
shr ecx, 0x12
test cl, 1
je case.0x514218.784
mov edx, dword [esi + 0xcc]
shr edx, 0x12
mov dword [esp + 0x14], 0x80
test dl, 1
je 0x514278
mov dword [esp + 0x14], 0x87
jmp 0x514278
call fcn.0050fc00
jmp 0x514258
call fcn.0050fc90
jmp 0x514258
mov eax, dword [esi]
mov edx, dword [eax + 0x284]
push edi
push ebp
call edx
jmp 0x514258
push ebp
call fcn.00513360
jmp 0x513952
lea eax, [esp + 0x14]
push eax
push edi
call fcn.0050f350
jmp 0x514258
test ebp, ebp
setne cl
movzx edx, cl
push edi
push edx
mov ecx, esi
call fcn.0050f420
jmp 0x514258
push edi
call fcn.00510960
jmp 0x514258
mov eax, edi
shr eax, 0x10
push eax
push edi
push ebp
call fcn.00512240
jmp 0x513952
mov eax, dword [edi + 4]
cmp eax, 1
jne 0x513a87
mov eax, dword [edi + 0x18]
mov ecx, dword [edi + 0x14]
push 0
mov dword [esp + 0x28], eax
mov eax, dword [esi + 0x28]
lea edx, [esp + 0x24]
push edx
push eax
mov eax, dword [0x68fb54]
mov dword [esp + 0x2c], ecx
push eax
lea ecx, [esp + 0x78]
call fcn.00505510
mov dword [esp + 0x70], esi
mov esi, dword [esi + 0x5c]
mov edx, dword [esi]
mov edx, dword [edx + 0x10]
lea eax, [esp + 0x68]
push eax
mov ecx, esi
mov dword [esp + 0x2d0], 1
call edx
lea ecx, [esp + 0x68]
mov dword [esp + 0x2cc], 0xffffffff
call fcn.005055b0
jmp 0x514278
cmp eax, 2
jne case.0x514218.784
mov eax, dword [edi + 8]
mov ecx, dword [0x68fb54]
push 0
push 0x67a444
push eax
push ecx
lea ecx, [esp + 0x78]
call fcn.00505510
mov dword [esp + 0x70], esi
mov esi, dword [esi + 0x5c]
mov edx, dword [esi]
mov edx, dword [edx + 0x10]
lea eax, [esp + 0x68]
push eax
mov ecx, esi
mov dword [esp + 0x2d0], 2
call edx
lea ecx, [esp + 0x68]
mov dword [esp + 0x2cc], 0xffffffff
call fcn.005055b0
jmp 0x514278
mov ecx, edi
shr ecx, 0x10
movsx edx, cx
movsx eax, di
lea ecx, [esp + 0x20]
push ecx
mov dword [esp + 0x24], eax
mov eax, dword [esi + 0x28]
mov dword [esp + 0x28], edx
mov edx, dword [0x68faec]
push eax
push edx
lea ecx, [esp + 0x74]
call fcn.005057c0
mov dword [esp + 0x2cc], 3
cmp ebp, dword [esi + 0x114]
je 0x513b31
push 0
push ebp
mov ecx, esi
call fcn.0050da30
test eax, eax
jne 0x513b33
mov eax, esi
mov dword [esp + 0x70], eax
mov eax, dword [eax + 0x5c]
mov edx, dword [eax]
mov edx, dword [edx + 0x10]
lea ecx, [esp + 0x68]
push ecx
mov ecx, eax
call edx
lea ecx, [esp + 0x68]
mov bl, al
mov dword [esp + 0x2cc], 0xffffffff
call fcn.0040b415
jmp 0x51425a
call fcn.0050cc00
mov dword [esp + 0x20], eax
test eax, eax
je case.0x514218.784
mov ecx, esi
call fcn.0050d7a0
call fcn.0050cc50
cmp eax, 0x10000000
jne case.0x514218.784
mov edi, dword [esp + 0x2dc]
mov ebp, dword [esp + 0x2d8]
mov eax, dword [esi]
mov edx, dword [eax + 0x28c]
push edi
push ebp
push ebx
mov ecx, esi
call edx
xor ebx, ebx
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], ebx
cmp ebp, ebx
je 0x513bd7
mov eax, dword [edi]
mov ecx, dword [edi + 4]
mov edx, dword [edi + 8]
mov dword [esp + 0x28], eax
mov eax, dword [edi + 0xc]
mov dword [esp + 0x18], edi
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x30], edx
mov dword [esp + 0x34], eax
jmp 0x513bf2
mov ecx, dword [edi]
mov edx, dword [edi + 4]
mov eax, dword [edi + 8]
mov dword [esp + 0x28], ecx
mov ecx, dword [edi + 0xc]
mov dword [esp + 0x2c], edx
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], ecx
push str.EDIT
push esi
lea ecx, [esp + 0x24]
call fcn.0050d880
push esi
lea ecx, [esp + 0x1c0]
mov dword [esp + 0x2d0], 4
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
mov dword [esp + 0x48], ebx
call fcn.00516c60
mov ecx, dword [esp + 0x2a4]
lea edx, [esp + 0x38]
push edx
mov edx, dword [esp + 0x20]
lea eax, [esp + 0x2c]
push eax
mov eax, dword [esp + 0x28]
push 1
push 1
push ecx
mov ecx, dword [eax + 0x10]
push edx
mov byte [esp + 0x2e4], 5
call ecx
test eax, eax
jne 0x513cb0
push 0xffffffffffffffff
push 0xffffffffffffffff
lea edx, [esp + 0x40]
push edx
call dword [sym.imp.USER32.dll_InflateRect]
cmp ebp, ebx
je 0x513c8d
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x3c]
mov dword [eax], ecx
mov ecx, dword [esp + 0x40]
mov dword [eax + 4], edx
mov edx, dword [esp + 0x44]
mov dword [eax + 8], ecx
mov dword [eax + 0xc], edx
jmp 0x513ca8
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x3c]
mov edx, dword [esp + 0x40]
mov dword [edi], eax
mov eax, dword [esp + 0x44]
mov dword [edi + 4], ecx
mov dword [edi + 8], edx
mov dword [edi + 0xc], eax
mov dword [esp + 0x14], 0x300
lea ecx, [esp + 0x1bc]
mov byte [esp + 0x2cc], 4
call fcn.005167d0
lea ecx, [esp + 0x1c]
mov dword [esp + 0x2cc], 0xffffffff
call fcn.0050cc30
jmp 0x514278
call fcn.0050cc00
mov dword [esp + 0x20], eax
test eax, eax
je case.0x514218.784
mov ecx, esi
call fcn.0050d7a0
call fcn.0050cc50
cmp eax, 0x10000000
jne case.0x514218.784
mov eax, dword [esp + 0x2dc]
mov ecx, dword [esp + 0x2d8]
mov edx, dword [esi]
mov edx, dword [edx + 0x28c]
push eax
push ecx
push ebx
mov ecx, esi
call edx
push str.EDIT
push esi
lea ecx, [esp + 0x20]
mov dword [esp + 0x1c], eax
call fcn.0050d880
mov ebx, 6
push esi
lea ecx, [esp + 0xc0]
mov dword [esp + 0x2d0], ebx
call fcn.00516bc0
lea eax, [esp + 0xb4]
push eax
mov ecx, esi
mov byte [esp + 0x2d0], 7
call fcn.004f9ea0
push eax
lea ecx, [esp + 0x2c]
call fcn.0050d600
lea ecx, [esp + 0x58]
push ecx
lea edx, [esp + 0x2c]
push edx
call fcn.0050d670
mov edx, dword [esp + 0x1ac]
mov ebp, dword [esp + 0x20]
mov edi, dword [esp + 0x28]
add esp, 8
lea eax, [esp + 0x48]
push eax
mov eax, dword [edi + 0x10]
lea ecx, [esp + 0x5c]
push ecx
push 1
push 1
push edx
push ebp
call eax
push 0xffffffffffffffff
push 0xffffffffffffffff
lea ecx, [esp + 0x50]
push ecx
call dword [sym.imp.USER32.dll_InflateRect]
mov edx, dword [esp + 0x54]
mov eax, dword [esp + 0x50]
mov ecx, dword [esp + 0x4c]
push edx
mov edx, dword [esp + 0x4c]
push eax
mov eax, dword [esp + 0x1ac]
push ecx
push edx
push eax
call dword [sym.imp.GDI32.dll_ExcludeClipRect]
mov ecx, dword [edi + 0x38]
push 1
push 1
push ebp
call ecx
test eax, eax
je 0x513e00
mov ecx, dword [esp + 0x1a4]
mov eax, dword [esi + 0x114]
lea edx, [esp + 0x58]
push edx
mov edx, dword [edi + 0xb4]
push ecx
push eax
call edx
mov eax, dword [esi]
mov edx, dword [eax + 0xa4]
mov ecx, esi
call edx
mov edx, dword [esp + 0x1a4]
movzx eax, al
neg eax
sbb eax, eax
push 0
and eax, 0xfffffffd
lea ecx, [esp + 0x5c]
push ecx
add eax, 4
push eax
mov eax, dword [edi + 8]
push 1
push edx
push ebp
call eax
lea ecx, [esp + 0xbc]
mov byte [esp + 0x2cc], bl
call fcn.00520420
lea ecx, [esp + 0x18]
mov dword [esp + 0x2cc], 0xffffffff
call fcn.0050cc30
jmp 0x514278
cmp ebx, 0x200
ja 0x51407f
je 0x514065
lea eax, [ebx - 0x101]
cmp eax, 0x37
ja case.0x514218.784
movzx ecx, byte [eax + 0x5143b4]
jmp dword [ecx*4 + 0x514390]
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x24]
push ecx
push edi
push ebp
mov ecx, esi
call fcn.0050ce60
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
push edx
push eax
push ecx
mov ecx, esi
call fcn.00510a10
jmp 0x514258
movzx ebx, bp
push edi
push ebx
mov ecx, esi
call fcn.00512960
add al, al
xor al, byte [esi + 0x11c]
and al, 2
xor byte [esi + 0x11c], al
test byte [esi + 0x11c], 2
je 0x513ee8
mov bl, 1
jmp 0x513f29
lea eax, [ebp - 8]
cmp eax, 0xd6
ja case.0x513ef9.10
movzx edx, byte [eax + 0x5143fc]
jmp dword [edx*4 + 0x5143ec]
mov bl, 1
jmp 0x513f29
xor bl, bl
jmp 0x513f29
push 0
push 0xffffffffffffffff
push 0xffffffffffffffff
push 0x204
mov ecx, esi
call fcn.00510c50
jmp 0x513f27
push 0
push edi
push ebx
mov ecx, esi
call fcn.00512870
mov bl, al
cmp dword [esp + 0x2d4], 0x104
je 0x51425e
jmp 0x51425a
mov ecx, esi
cmp ebp, 0x5d
jne 0x513f5b
push 0
push 0xffffffffffffffff
push 0xffffffffffffffff
push 0x205
call fcn.00510c50
jmp 0x514258
movzx eax, bp
push edi
push eax
call fcn.00512a00
jmp 0x514258
mov al, byte [esi + 0x11c]
test al, 2
je 0x513f81
and al, 0xfd
mov byte [esi + 0x11c], al
jmp 0x514278
push 1
movzx ecx, bp
push edi
push ecx
mov ecx, esi
call fcn.00512870
jmp 0x514258
lea edx, [esp + 0x20]
push edx
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x24]
push ecx
push edi
push ebp
mov ecx, esi
call fcn.0050ce90
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x18]
mov edx, dword [esi]
mov edx, dword [edx + 0x274]
push eax
mov eax, dword [esp + 0x20]
push ecx
xor ecx, ecx
cmp ebx, 0x114
setne cl
push eax
lea ecx, [ecx*4 + 4]
push ecx
mov ecx, esi
call edx
jmp 0x514258
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x1c]
push ecx
push edi
push ebp
mov ecx, esi
call fcn.0050cec0
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x18]
push edx
push eax
lea ecx, [esp + 0x1c]
push ecx
mov ecx, esi
call fcn.0050fd20
jmp 0x514258
push ebp
mov ecx, esi
call fcn.0050f910
mov bl, al
test bl, bl
je 0x51425e
mov dword [esp + 0x14], 0
jmp 0x51425a
mov edx, ebp
shr edx, 0x10
cmp edx, 0x10
jne case.0x514218.784
movzx eax, bp
push edi
push eax
call fcn.0057714a
add esp, 4
push eax
mov ecx, esi
call fcn.00510fb0
cmp eax, 0xffffffff
je case.0x514218.784
movzx eax, ax
or eax, 0x20000
jmp 0x514274
mov ecx, edi
shr ecx, 0x10
movsx edx, cx
push ebp
movsx eax, di
push edx
push eax
mov ecx, esi
call fcn.00512510
jmp 0x514258
cmp ebx, 0x2a3
ja 0x514204
je 0x5141f4
lea eax, [ebx - 0x201]
cmp eax, 0x32
ja case.0x514218.784
movzx ecx, byte [eax + 0x5144f4]
jmp dword [ecx*4 + 0x5144d4]
mov eax, dword [edi]
mov edx, dword [edi + 8]
mov ecx, dword [edi + 4]
sub edx, eax
mov dword [esp + 0x28], eax
mov eax, dword [edi + 0xc]
sub eax, ecx
mov dword [esp + 0x2c], ecx
lea ecx, [esp + 0x28]
inc edx
inc eax
push ecx
mov ecx, esi
mov dword [esp + 0x34], edx
mov dword [esp + 0x38], eax
call fcn.005105c0
mov bl, al
test bl, bl
je 0x51425e
mov eax, dword [esp + 0x28]
mov edx, dword [esp + 0x30]
mov ecx, dword [esp + 0x2c]
mov dword [edi], eax
lea eax, [edx + eax - 1]
mov edx, dword [esp + 0x34]
mov dword [edi + 8], eax
lea eax, [edx + ecx - 1]
mov dword [edi + 4], ecx
mov dword [edi + 0xc], eax
jmp 0x51425a
mov eax, dword [edi]
mov edx, dword [edi + 8]
mov ecx, dword [edi + 4]
sub edx, eax
mov dword [esp + 0x28], eax
mov eax, dword [edi + 0xc]
sub eax, ecx
mov dword [esp + 0x2c], ecx
lea ecx, [esp + 0x28]
inc edx
inc eax
push ecx
mov ecx, esi
mov dword [esp + 0x34], edx
mov dword [esp + 0x38], eax
call fcn.00510870
jmp 0x5140db
push edi
push ebp
mov ecx, esi
call fcn.00510d80
jmp 0x514258
mov ecx, edi
shr ecx, 0x10
movsx edx, cx
push ebp
movsx eax, di
push edx
push eax
push ebx
mov ecx, esi
call fcn.00510c50
mov bl, al
test bl, bl
jne 0x514278
cmp dword [esi + 0x118], 0
jne 0x51425a
cmp dword [esp + 0x2d4], 0x201
jne 0x51425a
mov edx, dword [esi]
mov eax, dword [edx + 0xd0]
mov ecx, esi
call eax
test al, al
je 0x51425a
mov edx, dword [esi]
mov eax, dword [edx + 0xc8]
mov ecx, esi
call eax
jmp 0x51425a
push edi
mov ecx, esi
call fcn.0050ff10
jmp 0x514258
push ebp
mov ecx, esi
call fcn.0050f9a0
jmp 0x514258
lea ecx, [esp + 0x1c]
push ecx
push edi
push ebp
mov ecx, esi
call fcn.005123a0
mov bl, al
test bl, bl
je 0x51395c
cmp byte [esp + 0x1c], 0
je 0x51395c
mov dword [esp + 0x14], 0x424d5144
jmp 0x51425a
test byte [esi + 0x11c], 1
je case.0x514218.784
call fcn.00510e90
jmp case.0x514218.784
lea eax, [ebx - 0x30f]
cmp eax, 0xa9
ja case.0x514218.784
movzx edx, byte [eax + 0x514540]
jmp dword [edx*4 + 0x514528]
push ebp
call fcn.00510340
jmp 0x514258
mov eax, edi
shr eax, 0x10
movsx ecx, ax
push ebp
push ecx
movsx edx, di
push edx
push ebx
mov ecx, esi
call fcn.00511120
jmp 0x514258
movzx eax, bp
push edi
push eax
call fcn.00512b10
jmp 0x514258
push ebp
call fcn.0050fdb0
jmp 0x514258
call fcn.00510010
mov bl, al
test bl, bl
jne 0x514278
mov ebx, dword [esp + 0x2d4]
mov edx, dword [esi]
mov eax, dword [edx + 0x28c]
push edi
push ebp
push ebx
mov ecx, esi
call eax
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x2c4]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2bc
ret 0xc