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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x34
push ebx
push esi
push edi
mov edi, dword [ebp + 0x10]
movzx eax, di
cmp eax, 0xc350
mov ebx, ecx
mov dword [esp + 0x3c], edi
mov dword [esp + 0x10], eax
jle 0x40cd0c
sub eax, 0x10000
mov dword [esp + 0x10], eax
mov ecx, dword [ebp + 8]
mov esi, edi
shr esi, 0x10
mov dword [esp + 0x14], esi
cmp ecx, 0x113
ja 0x40cef7
je 0x40cee8
add ecx, 0xfffffffb
cmp ecx, 0x9e
ja case.0x40cf10.518
movzx ecx, byte [ecx + 0x40d734]
jmp dword [ecx*4 + 0x40d714]
mov ecx, ebx
call fcn.0040dcb0
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov edx, dword [ebx + 4]
push edx
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je case.0x40cf10.518
push edi
mov ecx, ebx
call fcn.0040d9a0
jmp case.0x40cf10.518
mov ecx, ebx
call fcn.0040dcb0
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov dword [edi + 0x18], 0xa
mov dword [edi + 0x1c], 0xa
jmp case.0x40cf10.518
mov ecx, dword [ebx + 0xd8]
cmp ecx, 0xa
mov dword [ebx + 0xdc], 0
jl case.0x40cf10.518
cmp ecx, 0x11
jg case.0x40cf10.518
mov ecx, dword [ebx + 4]
mov dword [ebx + 0xe0], eax
lea eax, [ebx + 0xe8]
push eax
push ecx
mov dword [ebx + 0xe4], esi
call dword [sym.imp.USER32.dll_GetWindowRect]
mov edi, dword [sym.imp.USER32.dll_GetSystemMetrics]
push 0
mov dword [ebx + 0xdc], 1
call edi
push 1
call edi
cmp dword [ebx + 0xf0], eax
jl 0x40cdfd
cmp dword [ebx + 0xd8], 0xc
je case.0x40cf10.518
movzx eax, word [esp + 0x10]
mov ecx, dword [ebx + 0xd8]
movzx edx, si
shl edx, 0x10
or edx, eax
push edx
or ecx, 0xf000
push ecx
push 0x112
mov edx, dword [ebx + 4]
push edx
call dword [sym.imp.USER32.dll_PostMessageA]
mov eax, dword [esp + 0x3c]
push eax
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
mov eax, dword [ebx + 4]
push ecx
mov ecx, dword [ebx + 0x14]
push edx
push eax
call ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x108], 0
jne 0x40ce7f
mov eax, dword [ebx + 4]
lea ecx, [esp + 0x1c]
push ecx
mov dword [esp + 0x20], 0x10
mov dword [esp + 0x28], eax
mov dword [esp + 0x24], 2
call dword [sym.imp.COMCTL32.dll__TrackMouseEvent]
mov eax, dword [esp + 0x10]
mov dword [ebx + 0x108], 1
cmp dword [ebx + 0xdc], 0
je case.0x40cf10.518
mov ecx, dword [ebx + 0xd8]
cmp ecx, 0xa
jl case.0x40cf10.518
cmp ecx, 0x11
jg case.0x40cf10.518
cmp ecx, 0xa
jne case.0x40cf10.518
mov edx, dword [ebx + 0xe8]
sub edx, dword [ebx + 0xe0]
mov ecx, dword [ebx + 0xf0]
add edx, eax
mov eax, dword [ebx + 0xec]
mov dword [esp + 0x30], eax
lea eax, [esp + 0x2c]
push eax
push 1
mov dword [esp + 0x3c], ecx
mov ecx, dword [ebx + 4]
mov dword [esp + 0x34], edx
mov edx, dword [ebx + 0xf4]
push 0x214
push ecx
mov dword [esp + 0x48], edx
call dword [sym.imp.USER32.dll_SendMessageA]
jmp case.0x40cf10.518
mov esi, dword [ebp + 0xc]
mov ecx, ebx
call fcn.0040d900
jmp case.0x40cf10.518
add ecx, 0xfffffe00
cmp ecx, 0xa3
ja case.0x40cf10.518
movzx edx, byte [ecx + 0x40d7fc]
jmp dword [edx*4 + 0x40d7d4]
cmp dword [ebx + 0x108], 0
jne 0x40cf4c
mov eax, dword [ebx + 4]
lea ecx, [esp + 0x1c]
push ecx
mov dword [esp + 0x20], 0x10
mov dword [esp + 0x28], eax
mov dword [esp + 0x24], 2
call dword [sym.imp.COMCTL32.dll__TrackMouseEvent]
mov dword [ebx + 0x108], 1
mov edx, dword [ebx + 4]
push edx
call dword [sym.imp.USER32.dll_IsZoomed]
test eax, eax
jne 0x40d0cc
mov edx, dword [ebx + 4]
mov eax, dword [esp + 0x10]
lea ecx, [esp + 0x1c]
push ecx
push edx
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], esi
call dword [sym.imp.USER32.dll_GetWindowRect]
mov ecx, dword [ebx + 4]
lea eax, [esp + 0x2c]
push eax
push ecx
call dword [sym.imp.USER32.dll_ClientToScreen]
mov edx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x2c]
mov esi, dword [esp + 0x24]
mov edi, dword [esp + 0x20]
mov eax, dword [esp + 0x30]
sub ecx, edx
sub esi, edx
mov edx, dword [esp + 0x28]
sub eax, edi
sub edx, edi
mov edi, dword [ebx + 0xa0]
test edi, edi
jle 0x40d08a
cmp dword [ebx + 0xd0], 0
je 0x40d08a
cmp edi, 5
mov dword [esp + 0x18], 5
jl 0x40cfd4
mov dword [esp + 0x18], edi
test ecx, ecx
jl 0x40d016
mov edi, dword [ebx + 0xa0]
cmp ecx, edi
jge 0x40d016
test eax, eax
jl 0x40cff6
cmp eax, edi
jge 0x40cff6
mov dword [ebx + 0x18], 0xd
jmp 0x40d08a
mov ecx, edx
sub ecx, dword [esp + 0x18]
cmp eax, ecx
jl 0x40d00d
cmp eax, edx
jge 0x40d00d
mov dword [ebx + 0x18], 0x10
jmp 0x40d08a
mov dword [ebx + 0x18], 0xa
jmp 0x40d08a
mov edi, esi
sub edi, dword [esp + 0x18]
cmp ecx, edi
jl 0x40d057
cmp ecx, esi
jge 0x40d057
test eax, eax
jl 0x40d037
cmp eax, dword [esp + 0x18]
jge 0x40d037
mov dword [ebx + 0x18], 0xe
jmp 0x40d08a
mov ecx, edx
sub ecx, dword [esp + 0x18]
cmp eax, ecx
jl 0x40d04e
cmp eax, edx
jge 0x40d04e
mov dword [ebx + 0x18], 0x11
jmp 0x40d08a
mov dword [ebx + 0x18], 0xb
jmp 0x40d08a
test eax, eax
jl 0x40d06c
cmp eax, dword [ebx + 0xa0]
jge 0x40d06c
mov dword [ebx + 0x18], 0xc
jmp 0x40d08a
mov ecx, edx
sub ecx, dword [esp + 0x18]
cmp eax, ecx
jl 0x40d083
cmp eax, edx
jge 0x40d083
mov dword [ebx + 0x18], 0xf
jmp 0x40d08a
mov dword [ebx + 0x18], 0
mov eax, dword [ebx + 0x18]
add eax, 0xfffffff6
cmp eax, 7
ja case.default.0x40d095
jmp dword [eax*4 + 0x40d8a0]
push 0x7f84
jmp 0x40d0bd
push 0x7f85
jmp 0x40d0bd
push 0x7f82
jmp 0x40d0bd
push 0x7f83
jmp 0x40d0bd
push 0x7f00
push 0
call dword [sym.imp.USER32.dll_LoadCursorA]
push eax
call dword [sym.imp.USER32.dll_SetCursor]
cmp dword [ebp + 0xc], 1
jne 0x40d0e9
movzx eax, word [ebx + 0xe4]
movzx edx, word [ebx + 0xe0]
shl eax, 0x10
or eax, edx
mov dword [esp + 0x3c], eax
mov eax, dword [ebx]
mov edx, dword [eax + 0xa4]
mov ecx, ebx
call edx
test eax, eax
je 0x40d130
mov eax, dword [ebx]
mov edx, dword [eax + 0xa0]
mov ecx, ebx
call edx
push eax
mov edi, ebx
call fcn.0040efd0
test eax, eax
je case.0x40cf10.518
mov ecx, dword [esp + 0x14]
mov edx, dword [eax]
mov edx, dword [edx + 0xac]
push ecx
mov ecx, dword [esp + 0x14]
push ecx
mov ecx, eax
call edx
jmp case.0x40cf10.518
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
push eax
push ecx
mov esi, ebx
call fcn.0040f250
mov esi, eax
test esi, esi
je 0x40d1a0
mov edi, dword [ebx + 0x114]
test edi, edi
je 0x40d17f
mov edx, dword [esi]
mov eax, dword [edx + 0x10]
mov ecx, esi
call eax
mov edx, dword [edi]
mov edx, dword [edx + 0x10]
mov ecx, edi
mov dword [esp + 0x18], eax
call edx
mov ecx, dword [esp + 0x18]
cmp eax, ecx
je 0x40d17f
mov ecx, dword [ebx + 0x114]
mov eax, dword [ecx]
mov edx, dword [eax + 0xb0]
call edx
mov ecx, dword [esp + 0x14]
mov eax, dword [esi]
mov edx, dword [esp + 0x10]
mov eax, dword [eax + 0xac]
push ecx
push edx
mov ecx, esi
call eax
mov dword [ebx + 0x114], esi
jmp case.0x40cf10.518
mov ecx, dword [ebx + 0x114]
test ecx, ecx
je case.0x40cf10.518
mov edx, dword [ecx]
mov eax, dword [edx + 0xb0]
call eax
mov dword [ebx + 0x114], 0
jmp case.0x40cf10.518
mov ecx, dword [ebx + 0x114]
xor esi, esi
cmp ecx, esi
je 0x40d1e3
mov edx, dword [ecx]
mov eax, dword [edx + 0xb0]
call eax
mov dword [ebx + 0x114], esi
mov dword [ebx + 0x108], esi
jmp case.0x40cf10.518
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
push ecx
push edx
mov esi, ebx
call fcn.0040f250
test eax, eax
je 0x40d224
mov ecx, dword [esp + 0x14]
mov edx, dword [eax]
mov edx, dword [edx + 0xc0]
push ecx
mov ecx, dword [esp + 0x14]
push ecx
mov ecx, eax
call edx
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 4]
push 0xffffffffffffffff
push 0xffffffffffffffff
push 0x40b
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
mov edx, dword [ebx + 4]
lea ecx, [esp + 0x1c]
push ecx
push edx
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [ebx + 0xa4]
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
push ecx
mov dword [esp + 0x2c], eax
push edx
lea eax, [esp + 0x24]
push eax
call dword [sym.imp.USER32.dll_PtInRect]
test eax, eax
je case.0x40cf10.518
push edi
jmp 0x40ce2c
mov ecx, dword [ebx + 0x18]
add ecx, 0xfffffff6
cmp ecx, 7
ja case.default.0x40d27e
jmp dword [ecx*4 + 0x40d8c0]
push 0x7f84
jmp 0x40d29f
push 0x7f85
jmp 0x40d29f
push 0x7f82
jmp 0x40d29f
push 0x7f83
push 0
call dword [sym.imp.USER32.dll_LoadCursorA]
push eax
call dword [sym.imp.USER32.dll_SetCursor]
mov eax, dword [esp + 0x10]
mov ecx, dword [ebx + 0x18]
cmp ecx, 0xc
jne 0x40d2e5
movzx edx, si
movzx eax, ax
shl edx, 0x10
or edx, eax
push edx
push 0xf003
mov ecx, dword [ebx + 4]
push 0x112
push ecx
call dword [sym.imp.USER32.dll_PostMessageA]
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp ecx, 0xf
jne 0x40d2fd
movzx edx, si
movzx eax, ax
shl edx, 0x10
or edx, eax
push edx
push 0xf006
jmp 0x40d2cb
cmp ecx, 0xa
jne 0x40d315
movzx edx, si
movzx eax, ax
shl edx, 0x10
or edx, eax
push edx
push 0xf001
jmp 0x40d2cb
cmp ecx, 0xb
jne 0x40d32d
movzx edx, si
movzx eax, ax
shl edx, 0x10
or edx, eax
push edx
push 0xf002
jmp 0x40d2cb
cmp ecx, 0xd
jne 0x40d345
movzx edx, si
movzx eax, ax
shl edx, 0x10
or edx, eax
push edx
push 0xf004
jmp 0x40d2cb
cmp ecx, 0x11
jne 0x40d360
movzx edx, si
movzx eax, ax
shl edx, 0x10
or edx, eax
push edx
push 0xf008
jmp 0x40d2cb
cmp ecx, 0xe
jne 0x40d37b
movzx edx, si
movzx eax, ax
shl edx, 0x10
or edx, eax
push edx
push 0xf005
jmp 0x40d2cb
cmp ecx, 0x10
jne 0x40d396
movzx edx, si
movzx eax, ax
shl edx, 0x10
or edx, eax
push edx
push 0xf007
jmp 0x40d2cb
mov edi, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
push edi
push edx
mov esi, ebx
call fcn.0040f250
test eax, eax
je 0x40d3c8
mov ecx, dword [esp + 0x10]
mov edx, dword [eax]
mov edx, dword [edx + 0xb4]
push edi
push ecx
mov ecx, eax
call edx
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [ebx + 4]
lea eax, [esp + 0x2c]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov esi, dword [esp + 0x10]
mov edx, dword [ebx + 0xa4]
push edi
push esi
lea eax, [esp + 0x34]
push eax
mov dword [esp + 0x44], edx
call dword [sym.imp.USER32.dll_PtInRect]
test eax, eax
je 0x40d421
mov eax, dword [ebx + 4]
movzx ecx, di
movzx edx, si
shl ecx, 0x10
or ecx, edx
push ecx
push 2
push 0xa1
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
push 0xffffffffffffffff
push 0xffffffffffffffff
push 0x409
jmp 0x40ce1d
mov edx, dword [ebx + 4]
lea ecx, [esp + 0x1c]
push ecx
push edx
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [esp + 0x28]
sub eax, dword [ebx + 0xa8]
push edi
sub eax, dword [esp + 0x24]
push esi
lea ecx, [esp + 0x24]
push ecx
mov dword [esp + 0x2c], eax
call dword [sym.imp.USER32.dll_PtInRect]
test eax, eax
je 0x40d470
mov ecx, dword [ebx + 4]
movzx edx, di
movzx eax, si
shl edx, 0x10
or edx, eax
push edx
push 2
push 0xa1
push ecx
call dword [sym.imp.USER32.dll_PostMessageA]
push 0xffffffffffffffff
push 0xffffffffffffffff
push 0x409
jmp 0x40ce1d
mov eax, dword [ebp + 0xc]
dec eax
cmp eax, 7
ja case.0x40cf10.518
jmp dword [eax*4 + 0x40d8e0]
mov eax, dword [edi]
mov ecx, dword [edi + 8]
add eax, 3
cmp ecx, eax
jle 0x40d4a0
mov eax, ecx
mov dword [edi + 8], eax
jmp case.0x40cf10.518
mov eax, dword [edi + 8]
mov ecx, dword [edi]
add eax, 0xfffffffd
cmp ecx, eax
jge 0x40d4b6
mov eax, ecx
mov dword [edi], eax
mov eax, dword [edi + 0xc]
mov ecx, dword [edi + 4]
add eax, 0xfffffffd
cmp ecx, eax
jge 0x40d4c7
mov eax, ecx
mov dword [edi + 4], eax
jmp case.0x40cf10.518
mov eax, dword [edi]
mov ecx, dword [edi + 8]
add eax, 3
cmp ecx, eax
jle 0x40d4dd
mov eax, ecx
mov dword [edi + 8], eax
mov eax, dword [edi + 4]
mov ecx, dword [edi + 0xc]
add eax, 3
cmp ecx, eax
jle 0x40d4ef
mov eax, ecx
mov dword [edi + 0xc], eax
jmp case.0x40cf10.518
mov eax, dword [edi]
mov ecx, dword [edi + 8]
add eax, 3
cmp ecx, eax
jle 0x40d505
mov eax, ecx
mov dword [edi + 8], eax
jmp case.0x40d48b.3
mov eax, dword [edi + 4]
mov ecx, dword [edi + 0xc]
add eax, 3
cmp ecx, eax
jle 0x40d519
mov eax, ecx
mov dword [edi + 0xc], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi]
add eax, 0xfffffffd
cmp ecx, eax
jge 0x40d52a
mov eax, ecx
mov dword [edi], eax
jmp case.0x40cf10.518
mov eax, dword [ebx]
mov edx, dword [eax + 0x9c]
push 0
mov ecx, ebx
call edx
call dword [sym.imp.USER32.dll_ReleaseCapture]
mov edi, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
push edi
push eax
mov esi, ebx
call fcn.0040f250
test eax, eax
je case.0x40cf10.518
mov ecx, dword [esp + 0x10]
mov edx, dword [eax]
mov edx, dword [edx + 0xbc]
push edi
push ecx
mov ecx, eax
call edx
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov edi, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
push edi
push eax
mov esi, ebx
call fcn.0040f250
test eax, eax
je 0x40d5ad
mov ecx, dword [esp + 0x10]
mov edx, dword [eax]
mov edx, dword [edx + 0xb8]
push edi
push ecx
mov ecx, eax
call edx
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [ebx + 4]
lea eax, [esp + 0x1c]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [esp + 0x10]
mov edx, dword [ebx + 0xa4]
push edi
push eax
lea ecx, [esp + 0x24]
push ecx
mov dword [esp + 0x34], edx
call dword [sym.imp.USER32.dll_PtInRect]
test eax, eax
je case.0x40cf10.518
mov edi, dword [ebx + 0x128]
sub edi, dword [ebx + 0x124]
sar edi, 2
sub edi, 1
js 0x40d620
lea esi, [ebx + 0x118]
call fcn.0040f6d0
mov esi, dword [eax]
test esi, esi
je 0x40d61b
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov edx, dword [esi]
mov edx, dword [edx + 0x78]
push eax
push ecx
mov ecx, esi
call edx
test eax, eax
jne 0x40d63e
sub edi, 1
jns 0x40d5f3
mov eax, dword [ebx + 4]
push 0
push 0
push 0x41b
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
push 0x40d
xor eax, eax
mov ecx, esi
call fcn.00411e20
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
lea eax, [esp + 0x2c]
mov dword [esp + 0x2c], ecx
mov ecx, dword [ebx + 4]
push eax
push ecx
mov dword [esp + 0x38], edx
call dword [sym.imp.USER32.dll_ScreenToClient]
mov edx, dword [esp + 0x30]
mov eax, dword [esp + 0x2c]
push edx
push eax
mov esi, ebx
call fcn.0040f250
test eax, eax
je case.0x40cf10.518
mov ecx, dword [ebp + 0xc]
mov edx, dword [eax]
mov edx, dword [edx + 0xc8]
shr ecx, 0x10
push ecx
mov ecx, eax
call edx
test eax, eax
je case.0x40cf10.518
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx]
mov edx, dword [eax + 0xa4]
mov ecx, ebx
call edx
test eax, eax
je 0x40d6de
mov eax, dword [ebx]
mov edx, dword [eax + 0x9c]
push 0
mov ecx, ebx
call edx
call dword [sym.imp.USER32.dll_ReleaseCapture]
jmp case.0x40cf10.518
mov edi, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
push edi
push eax
mov esi, ebx
call fcn.0040f250
test eax, eax
je case.0x40cf10.518
mov ecx, dword [esp + 0x10]
mov edx, dword [eax]
mov edx, dword [edx + 0xc4]
push edi
push ecx
mov ecx, eax
call edx
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 0xc