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

Disassembly:
push ebp
lea ebp, [esp - 0x58]
sub esp, 0x510
mov eax, dword [ebp + 0x70]
push esi
xor esi, esi
cmp eax, esi
je 0x50238433
cmp dword [ebp + 0x74], esi
je 0x50238433
cmp dword [ebp + 0x64], esi
je 0x50238433
cmp dword [ebp + 0x78], esi
jg 0x50237ab1
xor eax, eax
inc eax
jmp 0x50238438
and byte [ebp - 0x78], 0
push ebx
push edi
lea ecx, [ebp - 0x168]
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], esi
mov dword [ebp - 0x7c], eax
mov dword [ebp + 0x54], esi
mov dword [ebp - 8], esi
call fcn.50236aaf
lea ecx, [ebp - 0x22c]
call fcn.5022c262
lea ecx, [ebp - 0x4b8]
call fcn.5022c262
mov dword [ebp + 0x48], esi
call fcn.5021cf4d
test eax, eax
setne byte [ebp + 0x4f]
xor eax, eax
push 0xc
pop ecx
lea edi, [ebp + 4]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x22c]
mov dword [ebp + 0x1c], eax
lea eax, [ebp - 0x4b8]
mov dword [ebp + 0x20], eax
mov eax, dword [ebp + 0x7c]
mov dword [ebp + 0x24], eax
mov eax, dword [ebp + 0x68]
cmp eax, esi
mov dword [ebp], esi
mov dword [ebp + 0x18], 7
je 0x50237b48
cmp word [eax], si
je 0x50237b48
push esi
push esi
push 0x104
lea ecx, [ebp - 0x3f4]
push ecx
push 0xffffffffffffffff
push eax
push esi
push esi
call dword [sym.imp.kernel32.dll_WideCharToMultiByte]
jmp 0x50237b78
push 0x104
lea eax, [ebp - 0x3f4]
push eax
push 0x3572
push dword [0x5029a6d4]
call dword [sym.imp.USER32.dll_LoadStringA]
cmp byte [ebp - 0x3f4], 0
jne 0x50237b78
mov dword [ebp - 0x3f4], 0x7d3f3c
mov ebx, dword [ebp + 0x6c]
cmp ebx, esi
jne 0x50237ba4
call fcn.50272bbe
cmp eax, esi
mov dword [ebp - 8], eax
jne 0x50237b95
mov esi, 0x80004005
jmp 0x502383f9
cmp dword [0x5029fa34], esi
mov ebx, eax
jne 0x50237ba4
mov dword [0x5029fa34], eax
lea eax, [ebp + 0x48]
push eax
lea eax, [ebp + 0x6c]
push eax
lea eax, [ebp + 0x50]
push eax
push dword [ebx]
mov dword [ebp + 0x50], esi
mov dword [ebp + 0x6c], esi
xor edi, edi
call fcn.50272bbe
mov eax, dword [ebx + 4]
and byte [ebp + 0x73], 0
cmp eax, esi
je 0x50237bdc
push eax
call dword [sym.imp.kernel32.dll_GlobalLock]
mov edi, eax
cmp word [edi + 0x3c], 2
sete byte [ebp + 0x73]
cmp dword [ebx + 8], esi
jne 0x50237c01
cmp dword [ebx + 4], esi
je 0x50237c01
cmp dword [ebx], esi
je 0x50237c01
cmp edi, esi
je 0x50237c0e
push edi
push dword [ebp + 0x48]
push dword [ebp + 0x6c]
push dword [ebp + 0x50]
call dword [sym.imp.GDI32.dll_CreateDCA]
mov dword [ebx + 8], eax
cmp edi, esi
je 0x50237c0e
push dword [ebx + 4]
call dword [sym.imp.kernel32.dll_GlobalUnlock]
cmp byte [ebp + 0x73], 0
je 0x50237c1d
cmp dword [ebp + 0x7c], esi
je 0x50237c1d
or dword [ebp + 0x18], 0x40
cmp dword [ebx + 8], esi
je 0x50238042
push dword [ebp + 0x48]
and byte [0x5029fa2c], 0
mov eax, dword [ebx + 8]
push dword [ebp + 0x6c]
mov dword [0x5029fa28], eax
mov dword [ebp + 4], eax
lea eax, [ebp - 0x3f4]
push eax
push dword [ebp + 0x64]
mov eax, dword [ebp + 0x60]
call fcn.50272bbe
push 0
push 4
push 0
call dword [sym.imp.GDI32.dll_CreatePen]
mov esi, dword [sym.imp.GDI32.dll_GetDeviceCaps]
push 0x58
push dword [ebp + 4]
mov dword [ebp + 0x44], eax
call esi
push 0x5a
push dword [ebp + 4]
mov dword [ebp + 0x64], eax
call esi
push 0xf
pop ecx
push 0x5a0
lea esi, [ebx + 0x20]
lea edi, [ebp - 0x74]
push eax
rep movsd dword es:[edi], dword [esi]
push dword [ebp - 0x74]
mov dword [ebp + 0x7c], eax
call dword [sym.imp.kernel32.dll_MulDiv]
mov dword [ebp - 0x74], eax
lea eax, [ebp - 0x74]
push eax
call dword [sym.imp.GDI32.dll_CreateFontIndirectA]
push eax
push dword [ebp + 4]
lea ecx, [ebp - 0x22c]
call fcn.50272bbe
test byte [ebx + 0x60], 1
je 0x50237cf0
push 0xf
pop ecx
push 0x5a0
push dword [ebp + 0x7c]
lea esi, [ebx + 0x80]
lea edi, [ebp - 0x74]
rep movsd dword es:[edi], dword [esi]
push dword [ebp - 0x74]
call dword [sym.imp.kernel32.dll_MulDiv]
mov dword [ebp - 0x74], eax
lea eax, [ebp - 0x74]
push eax
call dword [sym.imp.GDI32.dll_CreateFontIndirectA]
mov dword [ebx + 0xbc], eax
mov eax, dword [ebp + 0x44]
mov dword [ebx + 0xc0], eax
test byte [ebx + 0x60], 2
je 0x50237d31
push 0xf
pop ecx
push 0x5a0
push dword [ebp + 0x7c]
lea esi, [ebx + 0xe0]
lea edi, [ebp - 0x74]
rep movsd dword es:[edi], dword [esi]
push dword [ebp - 0x74]
call dword [sym.imp.kernel32.dll_MulDiv]
mov dword [ebp - 0x74], eax
lea eax, [ebp - 0x74]
push eax
call dword [sym.imp.GDI32.dll_CreateFontIndirectA]
mov dword [ebx + 0x11c], eax
mov eax, dword [ebp + 0x44]
mov dword [ebx + 0x120], eax
lea eax, [ebp - 0x74]
push eax
mov dword [ebp - 0x64], 0x2bc
call dword [sym.imp.GDI32.dll_CreateFontIndirectA]
push eax
push dword [ebp + 4]
lea ecx, [ebp - 0x4b8]
call fcn.50272bbe
mov esi, dword [sym.imp.GDI32.dll_GetDeviceCaps]
push 0x6e
push dword [ebp + 4]
call esi
push 0x6f
push dword [ebp + 4]
mov dword [ebp + 0x60], eax
call esi
push 0x70
push dword [ebp + 4]
mov edi, eax
call esi
push 0x71
push dword [ebp + 4]
mov dword [ebp + 0x70], eax
call esi
push dword [ebp + 0x7c]
mov esi, eax
push dword [ebx + 0x14]
push dword [ebx + 0xc]
call fcn.50272bbe
push dword [ebp + 0x64]
sub eax, esi
mov dword [ebp + 0x38], eax
push dword [ebx + 0x10]
push dword [ebx + 0xc]
call fcn.50272bbe
sub eax, dword [ebp + 0x70]
push dword [ebp + 0x7c]
mov dword [ebp + 0x34], eax
push dword [ebx + 0x1c]
push dword [ebx + 0xc]
call fcn.50272bbe
push dword [ebp + 0x64]
sub edi, esi
sub edi, eax
mov dword [ebp + 0x40], edi
push dword [ebx + 0x18]
push dword [ebx + 0xc]
call fcn.50272bbe
mov ecx, dword [ebp + 0x60]
sub ecx, dword [ebp + 0x70]
mov edi, dword [sym.imp.kernel32.dll_MulDiv]
sub ecx, eax
mov eax, ecx
push 8
mov dword [ebp + 0x3c], eax
sub eax, dword [ebp + 0x34]
push 5
push eax
call edi
push dword [ebp - 0x224]
mov dword [ebp - 4], eax
push dword [ebp + 4]
call dword [sym.imp.GDI32.dll_SelectObject]
test byte [ebx + 0x60], 0x10
mov dword [ebp + 0x64], eax
je 0x50237e56
mov ecx, dword [ebp + 0x74]
push 0xa
lea eax, [ebp - 0x58]
push eax
mov eax, dword [ebp + 0x78]
shl eax, 4
mov eax, dword [eax + ecx - 4]
inc eax
push eax
call dword [sym.imp.MSVCR70.dll__itoa]
add esp, 0xc
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.50104a0c
push eax
lea eax, [ebp - 0x58]
push eax
push dword [ebp + 4]
call dword [sym.imp.GDI32.dll_GetTextExtentPoint32A]
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x1b0]
add ecx, eax
mov eax, dword [ebp + 0x3c]
add dword [ebp + 0x34], ecx
sub eax, dword [ebp + 0x34]
push 8
push 5
push eax
call edi
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x1c4]
mov ecx, dword [ebp - 0x1b4]
add ecx, eax
mov dword [ebp + 0x70], ecx
mov ecx, dword [ebx + 0x5c]
imul ecx, dword [ebp - 0x184]
push 3
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp - 0x1c0]
mov dword [ebp - 0x14], ecx
xor ecx, ecx
push 2
push eax
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x38], ecx
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x28], eax
call edi
push 6
pop esi
cmp eax, esi
mov dword [ebp - 0x24], eax
jge 0x50237ea4
mov dword [ebp - 0x24], esi
jmp 0x50237ebc
push 0x48
push dword [ebp + 0x7c]
push esi
call edi
cmp dword [ebp - 0x24], eax
jl 0x50237ebc
push 0x48
push dword [ebp + 0x7c]
push esi
call edi
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x30], eax
test byte [ebx + 0x60], 1
je 0x50237f63
lea ecx, [ebp - 0x2f0]
call fcn.5022c262
push dword [ebx + 0xbc]
lea ecx, [ebp - 0x2f0]
push dword [ebp + 4]
call fcn.50272bbe
lea eax, [ebp + 0x34]
push eax
lea eax, [ebx + 0x64]
push eax
call dword [sym.imp.USER32.dll_CopyRect]
mov eax, dword [ebx + 0x68]
add eax, dword [ebp - 0x278]
push 0x48
push dword [ebp + 0x7c]
add eax, dword [ebp - 0x288]
push esi
mov dword [ebx + 0x70], eax
call edi
test byte [ebx + 0x74], 2
je 0x50237f1c
add eax, 7
mov ecx, dword [ebx + 0x70]
add ecx, eax
mov dword [ebp + 0x38], ecx
cmp dword [ebx + 0x78], 0
jne 0x50237f3c
test byte [ebx + 0x75], 1
jne 0x50237f3c
push dword [ebp + 0x68]
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov dword [ebx + 0x78], eax
cmp dword [ebx + 0x7c], 0
jne 0x50237f58
test byte [ebx + 0x75], 4
jne 0x50237f58
push 0x20
push 0
call dword [sym.imp.OLEAUT32.dll_SysReAllocStringLen]
mov dword [ebx + 0x7c], eax
mov dword [ebp], eax
lea ecx, [ebp - 0x2f0]
call fcn.5022c16f
test byte [ebx + 0x60], 2
je 0x50237fdb
lea ecx, [ebp - 0x2f0]
call fcn.5022c262
push dword [ebx + 0x11c]
lea ecx, [ebp - 0x2f0]
push dword [ebp + 4]
call fcn.50272bbe
lea eax, [ebp + 0x34]
push eax
lea eax, [ebx + 0xc4]
push eax
call dword [sym.imp.USER32.dll_CopyRect]
mov eax, dword [ebx + 0xd0]
sub eax, dword [ebp - 0x278]
push 0x48
push dword [ebp + 0x7c]
sub eax, dword [ebp - 0x288]
push esi
mov dword [ebx + 0xc8], eax
call edi
test byte [ebx + 0xd4], 1
je 0x50237fc5
add eax, 7
mov ecx, dword [ebx + 0xc8]
sub ecx, eax
mov dword [ebp + 0x40], ecx
lea ecx, [ebp - 0x2f0]
call fcn.5022c16f
push dword [ebp + 0x64]
push dword [ebp + 4]
call dword [sym.imp.GDI32.dll_SelectObject]
push 0
push 0
call fcn.50272bbe
cmp byte [0x5029fa2c], 0
je 0x50238002
mov dword [ebp + 0x54], 1
jmp 0x50238049
xor eax, eax
lea edi, [ebp - 0xa8]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov eax, dword [ebp + 0x48]
mov dword [ebp - 0xa0], eax
lea eax, [ebp - 0x3f4]
mov dword [ebp - 0xa4], eax
lea eax, [ebp - 0xa8]
push eax
push dword [ebp + 4]
mov dword [ebp - 0xa8], 0x14
call dword [sym.imp.GDI32.dll_StartDocA]
test eax, eax
jg 0x50238049
mov dword [ebp + 0x54], 0x80004005
xor esi, esi
cmp dword [ebp + 0x50], esi
je 0x50238058
push dword [ebp + 0x50]
call fcn.50258d3a
cmp dword [ebp + 0x6c], esi
je 0x50238065
push dword [ebp + 0x6c]
call fcn.50258d3a
cmp dword [ebp + 0x54], esi
jl 0x5023836c
mov eax, dword [ebp + 0x74]
mov eax, dword [eax + 4]
and byte [ebp + 0x7f], 0
lea ecx, [ebp - 0x10]
mov dword [ebp + 0x68], 1
mov dword [ebp + 0x60], esi
mov dword [ebp + 0x64], eax
call fcn.501ed283
jmp 0x50238338
cmp byte [ebp + 0x7f], 0
jne 0x5023834f
push dword [ebp]
lea eax, [ebp + 4]
push dword [ebp + 0x68]
push eax
push ebx
call fcn.50272bbe
test eax, eax
jl 0x5023834f
lea eax, [ebp + 0x34]
push eax
lea eax, [ebp + 8]
push eax
call dword [sym.imp.USER32.dll_CopyRect]
mov ecx, dword [ebp + 0x70]
mov eax, dword [ebp + 0xc]
add eax, ecx
mov ecx, dword [ebp + 0x74]
mov dword [ebp + 0x14], eax
mov eax, dword [ebp + 0x60]
shl eax, 4
lea eax, [eax + ecx + 0xc]
mov dword [ebp + 0x6c], eax
cmp byte [0x5029fa2c], 0
jne 0x50238324
mov eax, dword [ebp + 0x14]
cmp eax, dword [ebp + 0x40]
jge 0x50238324
mov eax, dword [ebp - 0xc]
mov esi, dword [ebp + 0x64]
or eax, 4
push eax
push esi
lea ecx, [ebp - 0x94]
call fcn.501ee3ff
test eax, eax
jl 0x50238320
test byte [ebx + 0x60], 0x10
je 0x50238130
lea eax, [esi + 1]
push eax
push dword [ebp - 0x1b0]
lea eax, [ebp + 8]
push eax
push dword [ebp + 4]
call fcn.50272bbe
mov eax, dword [ebp + 0x6c]
cmp esi, dword [eax - 8]
jne 0x5023813d
mov edi, dword [eax - 0xc]
jmp 0x5023813f
xor edi, edi
cmp esi, dword [eax]
jne 0x5023814b
mov eax, dword [ebp + 0x6c]
mov esi, dword [eax - 4]
jmp 0x50238151
mov esi, dword [ebp - 0x94]
mov eax, esi
sub eax, edi
test eax, eax
jle 0x502382d3
xor eax, eax
push eax
push 4
push eax
push eax
lea ecx, [ebp - 0x48]
call fcn.501fdcf0
mov eax, dword [ebp - 0x90]
mov dword [ebp - 0x164], eax
mov eax, dword [ebp - 0x88]
mov ecx, eax
neg ecx
sbb ecx, ecx
and ecx, esi
mov dword [ebp - 0x168], esi
mov dword [ebp - 0x15c], eax
xor esi, esi
cmp byte [ebp + 0x4f], 0
lea eax, [ebp - 0x48]
mov dword [ebp - 0x158], eax
mov eax, dword [ebp - 0x80]
sete byte [ebp + 0x50]
push dword [ebp + 0x50]
mov dword [ebp - 0x154], eax
push esi
lea eax, [ebp + 4]
mov dword [ebp - 0x160], ecx
push eax
lea ecx, [ebp - 0x168]
mov dword [ebp - 0x150], edi
call fcn.50272bbe
test eax, eax
mov dword [ebp + 0x54], eax
jl 0x50238347
mov eax, dword [ebp - 0x14c]
cmp eax, dword [ebp - 4]
jle 0x5023820b
push dword [ebp + 0x50]
neg eax
mov esi, eax
push esi
lea eax, [ebp + 4]
push eax
lea ecx, [ebp - 0x168]
mov dword [ebp - 0x150], edi
call fcn.50272bbe
test eax, eax
mov dword [ebp + 0x54], eax
jl 0x50238347
mov eax, dword [ebp - 0x150]
cmp eax, dword [ebp - 0x168]
jge 0x502382cb
add esi, dword [ebp - 0x14]
push dword [ebp + 0xc]
lea eax, [ebp - 0x38]
push dword [ebp + 0x10]
push eax
call dword [sym.imp.USER32.dll_OffsetRect]
push dword [ebp + 4]
lea edi, [ebp - 0x38]
call fcn.50272bbe
mov eax, dword [ebp + 0xc]
mov edi, dword [sym.imp.USER32.dll_OffsetRect]
neg eax
push eax
mov eax, dword [ebp + 0x10]
neg eax
push eax
lea eax, [ebp - 0x38]
push eax
call edi
push dword [ebp + 0x70]
lea eax, [ebp + 8]
push 0
push eax
call edi
mov eax, dword [ebp + 0x14]
cmp eax, dword [ebp + 0x40]
jle 0x5023829b
push dword [ebp]
lea eax, [ebp + 0x68]
push eax
lea eax, [ebp + 4]
push eax
push ebx
call fcn.50272bbe
test eax, eax
mov dword [ebp + 0x54], eax
jl 0x50238347
lea eax, [ebp + 0x34]
push eax
lea eax, [ebp + 8]
push eax
call dword [sym.imp.USER32.dll_CopyRect]
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 0x70]
add eax, ecx
mov dword [ebp + 0x14], eax
push dword [ebp + 0x50]
lea eax, [ebp + 4]
push esi
push eax
lea ecx, [ebp - 0x168]
call fcn.50272bbe
test eax, eax
mov dword [ebp + 0x54], eax
jl 0x50238347
mov eax, dword [ebp - 0x150]
cmp eax, dword [ebp - 0x168]
jl 0x50238220
lea ecx, [ebp - 0x48]
call fcn.501fd633
push dword [ebp + 0x70]
xor esi, esi
push esi
lea eax, [ebp + 8]
push eax
call dword [sym.imp.USER32.dll_OffsetRect]
mov eax, dword [ebp + 0x6c]
inc dword [ebp + 0x64]
mov ecx, dword [eax]
cmp ecx, dword [ebp + 0x64]
jge 0x5023830d
inc dword [ebp + 0x60]
mov ecx, dword [ebp + 0x60]
add eax, 0x10
cmp ecx, dword [ebp + 0x78]
mov dword [ebp + 0x6c], eax
jge 0x50238309
mov eax, dword [eax - 8]
mov dword [ebp + 0x64], eax
jmp 0x5023830d
mov byte [ebp + 0x7f], 1
push esi
push esi
call fcn.50272bbe
cmp byte [ebp + 0x7f], 0
je 0x502380dd
jmp 0x50238324
mov byte [ebp + 0x7f], 1
push dword [ebp + 0x68]
lea eax, [ebp + 4]
push eax
push ebx
call fcn.502374df
test eax, eax
jl 0x5023834f
inc dword [ebp + 0x68]
cmp byte [0x5029fa2c], 0
je 0x50238092
jmp 0x5023834f
lea ecx, [ebp - 0x48]
call fcn.501fd633
push dword [ebp + 4]
call dword [sym.imp.GDI32.dll_EndDoc]
cmp dword [ebp + 0x54], 0
jl 0x5023836c
xor eax, eax
cmp byte [0x5029fa2c], al
setne al
mov dword [ebp + 0x54], eax
mov eax, dword [0x5029fa30]
xor edi, edi
cmp eax, edi
je 0x50238384
push eax
call dword [sym.imp.USER32.dll_DestroyWindow]
mov dword [0x5029fa30], edi
xor esi, esi
inc esi
push esi
lea ecx, [ebp - 0x22c]
call fcn.5022c337
cmp dword [ebp + 0x48], edi
je 0x502383a0
push dword [ebp + 0x48]
call fcn.50258d3a
cmp dword [ebp + 0x44], edi
je 0x502383ae
push dword [ebp + 0x44]
call dword [sym.imp.GDI32.dll_DeleteObject]
cmp dword [ebp + 4], edi
je 0x502383bc
push dword [ebp + 4]
call dword [sym.imp.GDI32.dll_DeleteDC]
push esi
push esi
lea eax, [ebx + 0x64]
mov dword [ebx + 8], edi
push eax
mov dword [0x5029fa28], edi
mov dword [ebp + 4], edi
call fcn.5023632e
push esi
push esi
add ebx, 0xc4
push ebx
call fcn.5023632e
mov eax, dword [ebp - 8]
cmp eax, edi
je 0x502383f6
cmp eax, dword [0x5029fa34]
je 0x502383f6
push eax
call fcn.5023637e
mov esi, dword [ebp + 0x54]
lea ecx, [ebp - 0x4b8]
call fcn.5022c16f
lea ecx, [ebp - 0x22c]
call fcn.5022c16f
lea ecx, [ebp - 0x148]
call fcn.50228f21
lea ecx, [ebp - 0x94]
call fcn.501ed2a6
lea ecx, [ebp - 0x10]
call fcn.501ed2bf
pop edi
mov eax, esi
pop ebx
jmp 0x50238438
mov eax, 0x80004003
pop esi
add ebp, 0x58
leave
ret 0x20