Function at 0x401000
Capabilities:
Get graphical window text

Disassembly:
sub esp, 0x120
push ebx
push ebp
push esi
push edi
mov edi, ecx
push 0xfffffffffffffff0
mov dword [esp + 0x24], edi
xor ebx, ebx
mov eax, dword [edi + 4]
push eax
call dword [sym.imp.USER32.dll_GetWindowLongA]
mov ecx, dword [edi + 4]
mov esi, eax
push ecx
and esi, 0xb
call dword [sym.imp.USER32.dll_IsWindowEnabled]
cmp esi, 0xb
mov dword [esp + 0x28], eax
je 0x401041
cmp esi, 1
jne 0x401041
test eax, eax
je 0x401041
mov ebx, esi
mov edx, dword [edi + 4]
push 0
push 0
push 0xf2
push edx
call dword [sym.imp.USER32.dll_SendMessageA]
mov cl, byte [edi + 0xc]
and eax, 1
and ecx, 0x10
mov ebp, eax
mov esi, ecx
mov dword [esp + 0x24], esi
call fcn.004029a0
mov eax, dword [eax + 0x318]
test eax, eax
je 0x4010cf
test esi, esi
jne 0x4010a9
test ebp, ebp
jne 0x4010a9
mov cx, word [edi + 0xc]
test cl, 8
jne 0x4010a2
mov edx, dword [esp + 0x28]
test edx, edx
je 0x4010a2
test cl, 1
je 0x401099
mov ebx, 3
jmp 0x4010ae
neg ebx
sbb ebx, ebx
and ebx, 4
jmp 0x4010ae
mov ebx, 2
jmp 0x4010ae
mov ebx, 1
mov esi, dword [esp + 0x138]
mov edi, dword [esp + 0x134]
push 0
push 4
push ebx
push esi
push edi
mov ecx, eax
call fcn.00401c40
jmp 0x40118b
push 0xf
call fcn.004029b0
mov esi, dword [esp + 0x13c]
mov edi, dword [esp + 0x138]
push eax
push esi
push edi
call fcn.004059a0
mov edx, dword [esp + 0x30]
add esp, 0x10
test byte [edx + 0xc], 1
je 0x401146
cmp ebx, 1
jne 0x401122
mov eax, dword [esp + 0x24]
test eax, eax
je 0x401114
push 0xf
push 0xf
push 0x10
push 0x10
push 0x15
push 0x15
jmp 0x401181
push 0x10
push 0x16
push 0x15
push 0x14
push 0x15
push 0x15
jmp 0x401181
test ebp, ebp
je 0x40113a
push 0x16
push 0x10
push 0x14
push 0x15
push esi
push edi
call fcn.00405a90
add esp, 0x18
jmp 0x40118b
push 0xf
push 0xf
push 0x10
push 0x16
push 0x15
jmp 0x40117f
cmp ebx, 1
jne 0x401161
mov eax, dword [esp + 0x24]
push 0xf
test eax, eax
push 0xf
push 0x10
je 0x40111a
push 0x10
push 0x15
push 0x15
jmp 0x401181
test ebp, ebp
push 0xf
push 0xf
je 0x401179
push 0x14
push 0x10
push esi
push edi
call fcn.00405a90
add esp, 0x18
jmp 0x40118b
push 0xf
push 0xf
push 0x10
push 0x14
push esi
push edi
call fcn.00405b10
add esp, 0x20
mov ebx, dword [esp + 0x20]
lea eax, [esp + 0x30]
push pe_nt_image_headers32
push eax
mov ecx, dword [ebx + 4]
push ecx
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov edx, dword [ebx + 4]
push 0
push 0
push 0x31
push edx
mov dword [esp + 0x3c], 0
call dword [sym.imp.USER32.dll_SendMessageA]
test eax, eax
je 0x4011cb
push eax
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x2c], eax
mov eax, esi
push 0xfffffffffffffffe
push 0xfffffffffffffffe
mov ecx, dword [eax]
mov dword [esp + 0x18], ecx
mov edx, dword [eax + 4]
mov dword [esp + 0x1c], edx
mov ecx, dword [eax + 8]
mov dword [esp + 0x20], ecx
mov edx, dword [eax + 0xc]
lea eax, [esp + 0x18]
push eax
mov dword [esp + 0x28], edx
call dword [sym.imp.USER32.dll_InflateRect]
lea ecx, [esp + 0x10]
push 0x420
push ecx
lea edx, [esp + 0x38]
push 0xffffffffffffffff
push edx
push edi
call dword [sym.imp.USER32.dll_DrawTextA]
mov ecx, dword [esp + 0x18]
mov ebp, dword [esp + 0x10]
mov edx, dword [esi]
mov ebx, eax
mov eax, dword [esi + 8]
sub ecx, ebp
sub eax, edx
sub eax, ecx
sub eax, 4
cdq
sub eax, edx
mov edx, dword [esi + 4]
mov ebp, eax
mov eax, dword [esi + 0xc]
sub eax, edx
sub eax, ebx
sub eax, 4
cdq
sub eax, edx
sar eax, 1
add eax, 2
sar ebp, 1
mov dword [esp + 0x14], eax
add ebp, 2
add eax, ebx
mov dword [esp + 0x10], ebp
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x24]
add ebp, ecx
mov dword [esp + 0x18], ebp
mov ebp, dword [sym.imp.USER32.dll_OffsetRect]
test eax, eax
je 0x401273
push 1
lea eax, [esp + 0x14]
push 1
push eax
call ebp
push 1
push edi
call dword [sym.imp.GDI32.dll_SetBkMode]
mov eax, dword [esp + 0x28]
test eax, eax
je 0x4012b7
mov ecx, dword [esp + 0x20]
test byte [ecx + 0xc], 1
mov eax, dword [0x438dc0]
jne 0x401298
mov eax, dword [0x438dbc]
push eax
push edi
call dword [sym.imp.GDI32.dll_SetTextColor]
lea edx, [esp + 0x10]
push 0x20
push edx
lea eax, [esp + 0x38]
push 0xffffffffffffffff
push eax
push edi
call dword [sym.imp.USER32.dll_DrawTextA]
jmp 0x40130f
mov ecx, dword [0x438db0]
mov esi, dword [sym.imp.GDI32.dll_SetTextColor]
push ecx
push edi
call esi
push 1
lea edx, [esp + 0x14]
push 1
push edx
call ebp
mov ebx, dword [sym.imp.USER32.dll_DrawTextA]
lea eax, [esp + 0x10]
push 0x20
push eax
lea ecx, [esp + 0x38]
push 0xffffffffffffffff
push ecx
push edi
call ebx
mov edx, dword [0x438dc4]
push edx
push edi
call esi
push 0xffffffffffffffff
lea eax, [esp + 0x14]
push 0xffffffffffffffff
push eax
call ebp
lea ecx, [esp + 0x10]
push 0x20
push ecx
lea edx, [esp + 0x38]
push 0xffffffffffffffff
push edx
push edi
call ebx
mov eax, dword [esp + 0x2c]
test eax, eax
je 0x40131f
push eax
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x120
ret 8