Function at 0x403d50
Capabilities:
Check os version
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x52c61a
mov eax, dword fs:[0]
push eax
sub esp, 0x34
push ebx
push ebp
push esi
push edi
mov eax, dword [0x578700]
xor eax, esp
push eax
lea eax, [esp + 0x48]
mov dword fs:[0], eax
mov esi, ecx
call fcn.004078e2
mov eax, dword [esi + 0x230]
mov edi, dword [sym.imp.USER32.dll_SendMessageW]
push eax
mov eax, dword [esi + 0x20]
push 1
push 0x80
push eax
call edi
mov eax, dword [esi + 0x230]
mov ecx, dword [esi + 0x20]
push eax
push 0
push 0x80
push ecx
call edi
call fcn.00411e1b
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x403dcc
push 0x80004005
call fcn.00401320
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x18], eax
mov dword [esp + 0x50], 0
mov ecx, dword [esi + 0x110]
push ecx
lea edx, [esp + 0x1c]
push 0x558210
push edx
call fcn.004013f0
mov eax, dword [esp + 0x24]
add esp, 8
add eax, 0xfffffff0
mov dword [esp + 0x24], esp
mov edi, esp
push eax
mov dword [esp + 0x28], eax
call fcn.00406fb0
add eax, 0x10
add esp, 4
mov ebx, esi
mov dword [edi], eax
call fcn.00403c10
push 1
push str.EnableMouse
xor edi, edi
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x1f0], edi
mov dword [esi + 0x1ec], edi
call fcn.00417e6a
push 1
push str.EnableTouch1
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x13c], eax
call fcn.00417e6a
push 1
push str.EnableTouch2
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x140], eax
call fcn.00417e6a
push 1
push str.EnableTouch3
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x144], eax
call fcn.00417e6a
push 1
push str.EnableTouch4
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x148], eax
call fcn.00417e6a
mov dword [esi + 0x14c], eax
call dword [sym.imp.KERNEL32.dll_GetVersion]
movzx eax, al
mov ecx, 0x57fe30
cmp eax, 6
jb 0x403ed3
push edi
jmp 0x403ed5
push 1
push 0x5582b8
push 0x55823c
call fcn.00417e6a
push 3
push str.PenWidth
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x1bc], eax
mov dword [esi + 0x1c0], 1
call fcn.00417e6a
push 1
push str.InputSelect
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x1c4], eax
mov dword [esi + 0x8c], 0xffffffff
mov dword [esi + 0x1c8], edi
mov dword [esi + 0x1cc], edi
mov dword [esi + 0x1d0], edi
mov dword [esi + 0x1d4], edi
mov dword [esi + 0x1d8], edi
call fcn.00417e6a
push 0xff
push str.MouseColor
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x1e4], eax
call fcn.00417e6a
mov dword [esi + 0x90], eax
call fcn.00411e1b
xor ecx, ecx
cmp eax, edi
setne cl
cmp ecx, edi
jne 0x403f8d
push 0x80004005
call fcn.00401320
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x14], eax
mov byte [esp + 0x50], 1
mov edi, 1
lea ebp, [esi + 0x94]
lea ecx, [ecx]
push edi
lea ecx, [esp + 0x18]
push str.Touch_dColor
push ecx
call fcn.004013f0
add esp, 0xc
call fcn.005057b5
mov ecx, eax
shl ecx, 8
mov eax, 0x80010003
imul ecx
add edx, ecx
sar edx, 0xe
mov ebx, edx
shr ebx, 0x1f
add ebx, edx
call fcn.005057b5
mov ecx, eax
shl ecx, 8
mov eax, 0x80010003
imul ecx
add edx, ecx
sar edx, 0xe
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [esp + 0x1c], eax
call fcn.005057b5
mov ecx, eax
shl ecx, 8
mov eax, 0x80010003
imul ecx
add edx, ecx
sar edx, 0xe
mov eax, edx
shr eax, 0x1f
add eax, edx
movzx edx, byte [esp + 0x1c]
movzx eax, al
shl eax, 8
or eax, edx
mov edx, dword [esp + 0x14]
movzx ecx, bl
shl eax, 8
or eax, ecx
push eax
push edx
push 0x55823c
mov ecx, 0x57fe30
call fcn.00417e6a
mov dword [ebp], eax
inc edi
add ebp, 4
cmp edi, 0x20
jl 0x403fb0
push 1
push str.ShowGrid
push 0x55823c
mov ecx, 0x57fe30
call fcn.00417e6a
push 0x19
push str.GridWidth
push 0x55823c
mov ecx, 0x57fe30
mov dword [esi + 0x1dc], eax
call fcn.00417e6a
mov edi, dword [sym.imp.USER32.dll_GetSystemMetrics]
xor ebx, ebx
push ebx
mov dword [esi + 0x1e0], eax
mov dword [esi + 0x1f8], ebx
call edi
push 1
mov dword [esi + 0x124], eax
call edi
fld1
mov ecx, dword [esi + 0x124]
fst dword [esi + 0x134]
mov dword [esi + 0x128], eax
fstp dword [esi + 0x138]
mov dword [esi + 0x120], eax
mov dword [esi + 0x130], eax
mov eax, dword [esi + 0x20]
push eax
mov dword [esi + 0x114], ebx
mov dword [esi + 0x118], ebx
mov dword [esi + 0x11c], ecx
mov dword [esi + 0x12c], ecx
call dword [sym.imp.USER32.dll_GetDC]
push eax
call fcn.00410631
mov edi, eax
cmp edi, ebx
je 0x404165
mov ecx, dword [edi + 8]
mov ebx, dword [sym.imp.GDI32.dll_GetDeviceCaps]
push 0x58
push ecx
call ebx
mov edx, dword [edi + 8]
push 0x5a
push edx
movzx ebp, ax
call ebx
movzx ecx, ax
movsx eax, bp
mov dword [esp + 0x1c], eax
mov dword [esi + 0x12c], eax
fild dword [esp + 0x1c]
mov dword [esi + 0x130], eax
fld qword [0x558648]
movsx eax, cx
fld st(0)
fdivrp st(2)
mov dword [esp + 0x1c], eax
mov edx, dword [esi + 0x20]
fxch st(1)
fstp dword [esi + 0x134]
fild dword [esp + 0x1c]
fdivp st(1)
fstp dword [esi + 0x138]
mov ecx, dword [edi + 4]
push ecx
push edx
call dword [sym.imp.USER32.dll_ReleaseDC]
push 0x3f6
mov ecx, esi
xor edi, edi
xor ebx, ebx
call fcn.00407f83
mov dword [esp + 0x1c], eax
test eax, eax
je 0x404214
mov edx, dword [eax + 0x20]
lea ecx, [esp + 0x24]
push ecx
push edx
call dword [sym.imp.USER32.dll_GetWindowRect]
mov edi, dword [esp + 0x2c]
mov ecx, dword [esi + 0x124]
sub edi, dword [esp + 0x24]
mov ebx, dword [esp + 0x30]
sub ebx, dword [esp + 0x28]
mov eax, ecx
sub eax, edi
cdq
sub eax, edx
mov ebp, eax
lea eax, [ecx + edi]
cdq
sub eax, edx
mov ecx, eax
mov eax, dword [esi + 0x128]
sub eax, ebx
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x28], eax
mov eax, dword [esi + 0x128]
add eax, ebx
cdq
sub eax, edx
mov edx, dword [esp + 0x28]
sar eax, 1
sar ecx, 1
push 1
sar ebp, 1
mov dword [esp + 0x34], eax
mov dword [esp + 0x30], ecx
sub eax, edx
push eax
sub ecx, ebp
push ecx
push edx
mov dword [esp + 0x34], ebp
push ebp
mov ebp, dword [esp + 0x30]
mov ecx, ebp
call fcn.0040814e
cmp dword [esi + 0x1f0], 1
mov ecx, ebp
jne 0x40420d
push 0
jmp 0x40420f
push 5
call fcn.0040818e
push 0x3f4
mov ecx, esi
call fcn.00407f83
mov dword [esp + 0x1c], eax
test eax, eax
je 0x4042a0
mov ecx, dword [esi + 0x124]
mov eax, ecx
sub eax, edi
cdq
sub eax, edx
mov ebp, eax
lea eax, [ecx + edi]
cdq
sub eax, edx
mov ecx, eax
mov eax, dword [esi + 0x128]
sub eax, ebx
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x28], eax
mov eax, dword [esi + 0x128]
add eax, ebx
cdq
sub eax, edx
mov edx, dword [esp + 0x28]
sar ecx, 1
sar eax, 1
sub ecx, edi
push 1
sar ebp, 1
sub ebp, edi
mov dword [esp + 0x34], eax
mov dword [esp + 0x30], ecx
sub eax, edx
push eax
sub ecx, ebp
push ecx
push edx
mov dword [esp + 0x34], ebp
push ebp
mov ebp, dword [esp + 0x30]
mov ecx, ebp
call fcn.0040814e
cmp dword [esi + 0x1f0], 1
mov ecx, ebp
jne 0x404299
push 0
jmp 0x40429b
push 5
call fcn.0040818e
push 0x3f7
mov ecx, esi
call fcn.00407f83
mov dword [esp + 0x1c], eax
test eax, eax
je 0x40432a
mov ecx, dword [esi + 0x124]
mov eax, ecx
sub eax, edi
cdq
sub eax, edx
mov ebp, eax
lea eax, [ecx + edi]
cdq
sub eax, edx
mov ecx, eax
mov eax, dword [esi + 0x128]
sub eax, ebx
cdq
sub eax, edx
sar ecx, 1
add ecx, edi
sar ebp, 1
add ebp, edi
mov edi, eax
mov eax, dword [esi + 0x128]
add eax, ebx
cdq
sub eax, edx
sar edi, 1
sar eax, 1
push 1
mov dword [esp + 0x34], eax
sub eax, edi
mov dword [esp + 0x30], ecx
push eax
sub ecx, ebp
push ecx
push edi
mov dword [esp + 0x38], edi
mov edi, dword [esp + 0x2c]
push ebp
mov ecx, edi
mov dword [esp + 0x38], ebp
call fcn.0040814e
cmp dword [esi + 0x1f0], 1
mov ecx, edi
jne 0x404323
push 0
jmp 0x404325
push 5
call fcn.0040818e
mov eax, dword [esi + 0x128]
mov ecx, dword [esi + 0x124]
push 1
push eax
push ecx
push 0
push 0
mov ecx, esi
call fcn.0040814e
mov ecx, esi
call fcn.00402f70
call fcn.00403210
push 0x74
call fcn.004073f1
mov edi, eax
add esp, 4
mov dword [esp + 0x1c], edi
mov byte [esp + 0x50], 2
test edi, edi
je 0x404382
push 0
push 0x83
mov ecx, edi
call fcn.00407528
mov dword [edi], vtable.CMessageDlg.0
mov ecx, edi
jmp 0x404384
xor ecx, ecx
mov byte [esp + 0x50], 1
mov dword [esi + 0x78], ecx
test ecx, ecx
je 0x404436
mov edx, dword [ecx]
mov eax, dword [edx + 0x13c]
push 0
push 0x83
call eax
cmp eax, 1
jne 0x40441f
mov eax, dword [esi + 0x78]
mov edx, dword [eax + 0x20]
lea ecx, [esp + 0x34]
push ecx
push edx
call dword [sym.imp.USER32.dll_GetWindowRect]
mov ecx, dword [esp + 0x3c]
sub ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x40]
sub edx, dword [esp + 0x38]
mov eax, dword [esi + 0x124]
mov edi, dword [esi + 0x78]
sub eax, ecx
sub eax, 0x32
add edx, 0x32
add ecx, eax
push 1
mov dword [esp + 0x44], edx
mov dword [esp + 0x40], ecx
add edx, 0xffffffce
push edx
sub ecx, eax
push ecx
push 0x32
push eax
mov ecx, edi
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], 0x32
call fcn.0040814e
mov ecx, dword [esi + 0x78]
push 0
call fcn.0040818e
mov esi, dword [esi + 0x78]
mov eax, dword [esi + 0x20]
push eax
call dword [sym.imp.USER32.dll_UpdateWindow]
jmp 0x404436
mov ecx, dword [esi + 0x78]
test ecx, ecx
je 0x40442f
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push 1
call eax
mov dword [esi + 0x78], 0
mov byte [esp + 0x50], 0
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40445b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x20]
mov dword [esp + 0x50], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x404480
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 1
mov ecx, dword [esp + 0x48]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret