Function at 0x413180
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x56830e
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x94
mov ecx, dword [ebx + 0x20]
push esi
push edi
lea eax, [esp + 0x48]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetWindowRect]
mov eax, dword [ebx + 0x20]
lea edx, [esp + 0x58]
push edx
push eax
call dword [sym.imp.USER32.dll_GetClientRect]
lea ecx, [esp + 0x58]
push ecx
mov ecx, ebx
call sub.MFC71.DLL_CWnd::ClientToScreen
xor edi, edi
mov ecx, ebx
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], edi
mov dword [esp + 0x24], edi
mov dword [esp + 0x28], edi
call sub.MFC71.DLL_CWnd::GetExStyle
push eax
push edi
mov ecx, ebx
call sub.MFC71.DLL_CWnd::GetStyle
push eax
lea edx, [esp + 0x28]
push edx
call dword [sym.imp.USER32.dll_AdjustWindowRectEx]
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0x1c]
mov esi, dword [esp + 0x20]
mov ecx, eax
sub ecx, edx
mov dword [esp + 0x2c], ecx
mov ecx, dword [esp + 0x4c]
mov edx, ecx
sub edx, esi
mov esi, dword [esp + 0x24]
mov dword [esp + 0x30], edx
mov edx, dword [esp + 0x50]
neg ecx
push ecx
neg eax
sub edx, esi
push eax
mov dword [esp + 0x3c], edx
mov edx, dword [esp + 0x64]
lea eax, [esp + 0x34]
push eax
mov dword [esp + 0x44], edx
call dword [sym.imp.USER32.dll_OffsetRect]
cmp dword [0x68c8bc], 5
jne 0x4132a4
call fcn.00557e80
mov esi, eax
call fcn.005565e0
test eax, eax
jne 0x4132a4
mov edx, dword [ebx]
push edi
push 0x5c598c
push 0x5c59a8
push edi
mov ecx, ebx
call dword [edx + 0x144]
push eax
call sub.MSVCR71.dll___RTDynamicCast
add esp, 0x14
cmp eax, edi
je 0x4132a4
mov edi, ebx
call fcn.004113a0
mov eax, dword [eax + 0x20]
push eax
call dword [sym.imp.USER32.dll_IsZoomed]
test eax, eax
je 0x4132a2
push 0x36
call dword [sym.imp.USER32.dll_GetSystemMetrics]
imul eax, eax, 0xfffffffd
add dword [esp + 0x34], eax
xor edi, edi
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], vtable.CRgn.0
lea ecx, [esp + 0x2c]
push ecx
mov dword [esp + 0xa8], edi
call dword [sym.imp.GDI32.dll_CreateRectRgnIndirect]
push eax
lea ecx, [esp + 0x10]
call sub.MFC71.DLL_CGdiObject::Attach
mov edx, dword [ebx + 0x89c]
push edx
call dword [sym.imp.USER32.dll_GetMenuItemCount]
xor esi, esi
cmp eax, edi
mov dword [esp + 0x3c], eax
jbe 0x4133a1
jmp 0x4132f0
xor eax, eax
mov ecx, 0xc
lea edi, [esp + 0x68]
rep stosd dword es:[edi], eax
mov ecx, dword [ebx + 0x89c]
mov eax, 0x30
mov dword [esp + 0x68], eax
mov dword [esp + 0x6c], eax
lea eax, [esp + 0x68]
push eax
push 1
push esi
push ecx
call dword [sym.imp.USER32.dll_GetMenuItemInfoA]
mov eax, dword [esp + 0x70]
test ah, 1
je 0x413394
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], vtable.CRgn.0
mov byte [esp + 0xa4], 1
mov eax, dword [esp + 0x88]
test eax, eax
je 0x41337b
add eax, 0x34
push eax
call dword [sym.imp.GDI32.dll_CreateRectRgnIndirect]
push eax
lea ecx, [esp + 0x18]
call sub.MFC71.DLL_CGdiObject::Attach
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x10]
push 4
push edx
push eax
push eax
call dword [sym.imp.GDI32.dll_CombineRgn]
lea ecx, [esp + 0x14]
call sub.MFC71.DLL_CGdiObject::DeleteObject
mov byte [esp + 0xa4], 0
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], vtable.CGdiObject.0
call sub.MFC71.DLL_CGdiObject::DeleteObject
mov eax, dword [esp + 0x3c]
inc esi
cmp esi, eax
jb 0x4132f0
mov eax, dword [ebx + 0x20]
push eax
call dword [sym.imp.USER32.dll_GetWindowDC]
push eax
call sub.MFC71.DLL_CDC::FromHandle
mov ecx, dword [0x68c9b4]
mov edi, eax
mov eax, dword [ecx + 0x34]
mov eax, dword [eax + 0x1b0]
push eax
lea ecx, [esp + 0x44]
call sub.MFC71.DLL_CBrush::CBrush
mov byte [esp + 0xa4], 2
mov edx, dword [esp + 0x44]
mov eax, dword [esp + 0x10]
mov ecx, dword [edi + 4]
push edx
push eax
push ecx
call dword [sym.imp.GDI32.dll_FillRgn]
mov edx, dword [edi + 4]
mov eax, dword [ebx + 0x20]
push edx
push eax
call dword [sym.imp.USER32.dll_ReleaseDC]
lea ecx, [esp + 0xc]
call sub.MFC71.DLL_CGdiObject::DeleteObject
mov byte [esp + 0xa4], 0
mov esi, vtable.CGdiObject.0
lea ecx, [esp + 0x40]
mov dword [esp + 0x40], esi
call sub.MFC71.DLL_CGdiObject::DeleteObject
mov dword [esp + 0xa4], 0xffffffff
lea ecx, [esp + 0xc]
mov dword [esp + 0xc], esi
call sub.MFC71.DLL_CGdiObject::DeleteObject
mov ecx, dword [esp + 0x9c]
pop edi
mov dword fs:[0], ecx
pop esi
mov esp, ebp
pop ebp
ret