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

Disassembly:
sub esp, 0xa0
mov eax, dword [0x517b5c]
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov cl, byte [0x517b60]
xor ebx, ebx
mov dword [esp + 0x48], eax
mov byte [esp + 0x4c], cl
mov ecx, 6
xor eax, eax
lea edi, [esp + 0x4d]
mov dword [esp + 0x2c], 9
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x3c], 0x190
mov byte [esp + 0x40], bl
mov byte [esp + 0x41], bl
mov byte [esp + 0x42], bl
mov byte [esp + 0x43], 0x86
mov byte [esp + 0x44], 2
mov byte [esp + 0x45], 1
mov byte [esp + 0x46], bl
mov byte [esp + 0x47], bl
rep stosd dword es:[edi], eax
mov ebp, dword [sym.imp.USER32.dll_GetDesktopWindow]
stosw word es:[edi], ax
stosb byte es:[edi], al
call ebp
push eax
call dword [sym.imp.USER32.dll_GetDC]
mov edi, eax
push 0x48
push 0x5a
push edi
call dword [sym.imp.GDI32.dll_GetDeviceCaps]
push eax
push 9
call dword [sym.imp.KERNEL32.dll_MulDiv]
neg eax
push 0x518844
lea ecx, [esi + 0xf4]
mov dword [esp + 0x30], eax
call sub.MFC42.DLL_CString::operator_2
lea edx, [esp + 0x2c]
mov byte [esp + 0x41], 1
push edx
call dword [sym.imp.GDI32.dll_CreateFontIndirectA]
push eax
lea ecx, [esi + 0xf8]
call sub.MFC42.DLL_CGdiObject::Attach
push edi
mov dword [esi + 0xe8], 0xff3c00
mov dword [esi + 0xec], 0xb71787
call ebp
push eax
call dword [sym.imp.USER32.dll_ReleaseDC]
mov ecx, dword [esi + 0x80]
lea eax, [esp + 0x1c]
push eax
push ecx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], ebx
call dword [sym.imp.USER32.dll_GetWindowRect]
mov ecx, dword [esp + 0x24]
mov edi, dword [esp + 0x1c]
sub ecx, edi
mov eax, 0x4ec4ec4f
sub ecx, 5
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
mov eax, 0x66666667
mov dword [esp + 0x7c], edx
imul ecx
sar edx, 1
mov eax, edx
mov dword [esp + 0x8c], ebx
shr eax, 0x1f
add edx, eax
mov eax, 0x4ec4ec4f
mov edi, edx
lea edx, [ecx + ecx]
imul edx
sar edx, 2
mov eax, edx
mov dword [esp + 0x80], edi
shr eax, 0x1f
add edx, eax
mov eax, 0x4ec4ec4f
mov ebp, edx
imul ecx
sar edx, 2
mov eax, edx
mov dword [esp + 0x84], ebp
shr eax, 0x1f
add edx, eax
xor eax, eax
sub ecx, edx
mov dword [esp + 0x68], 0x51883c
sub ecx, ebp
mov dword [esp + 0x6c], 0x518834
sub ecx, edi
lea edi, [esp + 0x90]
mov dword [esp + 0x88], ecx
mov ecx, 8
rep stosd dword es:[edi], eax
mov ecx, 0x51883c
xor edi, edi
test ecx, ecx
mov dword [esp + 0x70], 0x518828
mov dword [esp + 0x74], 0x51881c
mov dword [esp + 0x78], ebx
je 0x4104ef
mov ebp, 0xf
cmp edi, 1
mov dword [esp + 0x90], ebp
je 0x4104a4
cmp edi, 3
mov dword [esp + 0x94], 2
jne 0x4104ab
mov dword [esp + 0x94], ebx
mov edx, dword [esp + eax + 0x7c]
lea eax, [esp + 0x90]
mov dword [esp + 0x9c], ecx
mov ecx, dword [esi + 0x80]
push eax
push edi
push 0x101b
push ecx
mov dword [esp + 0xb4], edi
mov dword [esp + 0xa8], edx
call dword [sym.imp.USER32.dll_SendMessageA]
inc edi
lea eax, [edi*4]
mov ecx, dword [esp + eax + 0x68]
cmp ecx, ebx
jne 0x410488
mov edx, dword [esi + 0x80]
mov edi, dword [sym.imp.USER32.dll_SendMessageA]
push ebx
push ebx
push 0x1037
push edx
call edi
or al, 0x21
push eax
mov eax, dword [esi + 0x80]
push ebx
push 0x1036
push eax
call edi
push ebx
push ebx
push 0xff
push 0x10
lea ecx, [esi + 0x104]
push 0x10
call sub.MFC42.DLL_CImageList::Create
call sub.MFC42.DLL_AfxGetModuleState
push 0x126
push 0xe
push 0x126
call sub.MFC42.DLL_AfxFindResourceHandle
mov edi, dword [sym.imp.USER32.dll_LoadIconA]
push eax
call edi
mov ecx, dword [esi + 0x108]
mov ebp, dword [sym.imp.COMCTL32.dll_ImageList_ReplaceIcon]
push eax
push 0xffffffffffffffff
push ecx
call ebp
call sub.MFC42.DLL_AfxGetModuleState
push 0x125
push 0xe
push 0x125
call sub.MFC42.DLL_AfxFindResourceHandle
push eax
call edi
mov edx, dword [esi + 0x108]
push eax
push 0xffffffffffffffff
push edx
call ebp
call sub.MFC42.DLL_AfxGetModuleState
push 0x127
push 0xe
push 0x127
call sub.MFC42.DLL_AfxFindResourceHandle
push eax
call edi
push eax
mov eax, dword [esi + 0x108]
push 0xffffffffffffffff
push eax
call ebp
call sub.MFC42.DLL_AfxGetModuleState
push 0x128
push 0xe
push 0x128
call sub.MFC42.DLL_AfxFindResourceHandle
push eax
call edi
mov ecx, dword [esi + 0x108]
push eax
push 0xffffffffffffffff
push ecx
call ebp
call sub.MFC42.DLL_AfxGetModuleState
push 0x129
push 0xe
push 0x129
call sub.MFC42.DLL_AfxFindResourceHandle
push eax
call edi
mov edx, dword [esi + 0x108]
push eax
push 0xffffffffffffffff
push edx
call ebp
call sub.MFC42.DLL_AfxGetModuleState
push 0x12a
push 0xe
push 0x12a
call sub.MFC42.DLL_AfxFindResourceHandle
push eax
call edi
push eax
mov eax, dword [esi + 0x108]
push 0xffffffffffffffff
push eax
call ebp
call sub.MFC42.DLL_AfxGetModuleState
push 0x12b
push 0xe
push 0x12b
call sub.MFC42.DLL_AfxFindResourceHandle
push eax
call edi
mov ecx, dword [esi + 0x108]
push eax
push 0xffffffffffffffff
push ecx
call ebp
call sub.MFC42.DLL_AfxGetModuleState
push 0x12c
push 0xe
push 0x12c
call sub.MFC42.DLL_AfxFindResourceHandle
push eax
call edi
mov edx, dword [esi + 0x108]
push eax
push 0xffffffffffffffff
push edx
call ebp
lea eax, [esi + 0x104]
cmp eax, ebx
jne 0x41066f
xor eax, eax
jmp 0x410672
mov eax, dword [eax + 4]
mov ebp, dword [sym.imp.USER32.dll_SendMessageA]
push eax
mov eax, dword [esi + 0x80]
push 1
push 0x1003
push eax
call ebp
push eax
call sub.MFC42.DLL_CImageList::FromHandle
lea edi, [esi + 0x114]
push edi
call fcn.00411280
mov ecx, eax
call fcn.0040ecd0
push edi
call fcn.00411280
mov ecx, eax
call fcn.0040bc40
mov ecx, dword [esi + 0x80]
push ebx
push ebx
push 0x1009
push ecx
call ebp
mov ebp, dword [esi + 0x11c]
mov edi, dword [esi + 0x118]
mov eax, ebp
mov dword [esp + 0x14], ebp
sub eax, edi
mov dword [esp + 0x18], edi
and al, 0xfc
cmp eax, 0x40
jg 0x4106f3
mov edx, dword [esp + 0x10]
push ebx
push edx
push ebp
push edi
call fcn.004116c0
add esp, 0x10
jmp 0x4107a4
mov eax, dword [esp + 0x10]
push eax
push eax
mov eax, dword [ebp - 4]
push eax
mov eax, ebp
sub eax, edi
sar eax, 2
cdq
sub eax, edx
mov edx, dword [edi]
sar eax, 1
mov ecx, dword [edi + eax*4]
push ecx
push edx
call fcn.00411760
add esp, 0x10
push eax
push ebp
push edi
call fcn.004117d0
mov ecx, ebp
mov edx, eax
sub ecx, eax
sub edx, edi
add esp, 0x10
and ecx, 0xfffffffc
and edx, 0xfffffffc
mov dword [esp + 0x10], eax
cmp ecx, edx
push ebx
jg 0x41074f
mov ecx, dword [esp + 0x14]
push ecx
push ebp
push eax
call fcn.00411470
mov ebp, dword [esp + 0x20]
add esp, 0x10
jmp 0x410762
mov edx, dword [esp + 0x14]
push edx
push eax
push edi
call fcn.00411470
mov edi, dword [esp + 0x20]
add esp, 0x10
mov eax, ebp
sub eax, edi
and al, 0xfc
cmp eax, 0x40
jg 0x4106f3
mov eax, dword [esp + 0x18]
mov ebp, dword [esp + 0x10]
push ebx
push ebp
lea edi, [eax + 0x40]
push edi
push eax
call fcn.004116c0
mov eax, dword [esp + 0x24]
add esp, 0x10
cmp edi, eax
je 0x4107a4
mov ecx, dword [edi]
push ebp
push ecx
push edi
call fcn.00411670
mov eax, dword [esp + 0x20]
add edi, 4
add esp, 0xc
cmp edi, eax
jne 0x41078c
mov eax, dword [esi + 0x118]
cmp eax, ebx
jne 0x4107b2
xor ebp, ebp
jmp 0x4107bd
mov ebp, dword [esi + 0x11c]
sub ebp, eax
sar ebp, 2
xor edi, edi
cmp ebp, ebx
jbe 0x4107dd
mov edx, dword [esi + 0x118]
mov eax, dword [edx + edi*4]
cmp eax, ebx
je 0x4107d8
push eax
mov ecx, esi
call fcn.00410c10
inc edi
cmp edi, ebp
jb 0x4107c3
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xa0
ret