Function at 0x4047d6
Capabilities:
Get graphical window text

Disassembly:
push ebp
lea ebp, [esp - 0xff4]
mov eax, 0x1074
call fcn.00406d30
mov eax, dword [0x4171b0]
xor eax, ebp
mov dword [ebp + 0xff0], eax
mov eax, dword [ebp + 0x1000]
push ebx
mov ebx, dword [ebp + 0xffc]
push esi
push edi
lea edx, [ebp - 0x24]
push edx
lea edx, [ebp - 0x28]
push edx
push eax
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x38], eax
call fcn.004046cc
mov byte [ebp - 0x11], al
lea eax, [ebp - 0x4c]
push eax
push ebx
call dword [sym.imp.USER32.dll_GetWindowRect]
lea eax, [ebp - 0x70]
push eax
push ebx
call dword [sym.imp.USER32.dll_GetClientRect]
mov ecx, dword [ebp - 0x44]
sub ecx, dword [ebp - 0x4c]
mov esi, dword [ebp - 0x40]
sub esi, dword [ebp - 0x48]
inc ecx
inc esi
mov eax, ecx
sub eax, dword [ebp - 0x68]
mov edi, esi
sub edi, dword [ebp - 0x64]
cmp byte [ebp - 0x11], 0
mov dword [ebp - 0x34], eax
je 0x4048fa
cmp byte [ebp + 0x1004], 0
jne 0x40493d
mov eax, dword [ebp - 0x68]
imul eax, dword [ebp - 0x28]
cdq
push 0x64
pop ebx
idiv ebx
add eax, dword [ebp - 0x34]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x64]
imul eax, dword [ebp - 0x24]
cdq
idiv ebx
mov ebx, eax
mov eax, ecx
sub eax, dword [ebp - 0x1c]
add ebx, edi
cdq
sub eax, edx
mov ecx, eax
mov eax, esi
sub eax, ebx
cdq
sub eax, edx
sar ecx, 1
add ecx, dword [ebp - 0x4c]
mov esi, eax
sar esi, 1
add esi, dword [ebp - 0x48]
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x20], ecx
test ecx, ecx
jge 0x4048b2
and dword [ebp - 0x20], 0
test esi, esi
jge 0x4048b8
xor esi, esi
mov ebx, dword [ebp - 0x30]
push 0xfffffffffffffff0
push ebx
mov dword [ebp - 0x18], 0x204
call dword [sym.imp.USER32.dll_GetWindowLongW]
test eax, 0x800
jne 0x4048d9
mov dword [ebp - 0x18], 0x206
push dword [ebp - 0x18]
push dword [ebp - 0x2c]
push dword [ebp - 0x1c]
push esi
push dword [ebp - 0x20]
push 0
push ebx
call dword [sym.imp.USER32.dll_SetWindowPos]
lea eax, [ebp - 0x4c]
push eax
push ebx
call dword [sym.imp.USER32.dll_GetWindowRect]
cmp byte [ebp + 0x1004], 0
mov esi, 0x400
jne 0x404942
push esi
lea eax, [ebp + 0x7f0]
push eax
push ebx
call dword [sym.imp.USER32.dll_GetWindowTextW]
push dword [ebp - 0x38]
mov ecx, dword [ebp - 0x3c]
push 1
push esi
lea eax, [ebp + 0x7f0]
push eax
push eax
call fcn.00404522
lea eax, [ebp + 0x7f0]
push eax
push ebx
call dword [sym.imp.USER32.dll_SetWindowTextW]
jmp 0x404942
mov esi, 0x400
push 8
call dword [sym.imp.USER32.dll_GetSystemMetrics]
push 5
push ebx
sub edi, eax
call dword [sym.imp.USER32.dll_GetWindow]
and dword [ebp - 0x18], 0
mov ebx, eax
mov dword [ebp - 0x50], ebx
jmp 0x404a95
cmp dword [ebp - 0x18], 0x200
jge 0x404a9d
push esi
lea eax, [ebp + 0x7f0]
push eax
push ebx
call dword [sym.imp.USER32.dll_GetWindowTextW]
cmp word [ebp + 0x7f0], 0
je 0x4049ad
push dword [ebp - 0x38]
mov ecx, dword [ebp - 0x3c]
push 1
push esi
lea eax, [ebp + 0x7f0]
push eax
push eax
call fcn.00404522
lea eax, [ebp + 0x7f0]
push eax
push ebx
call dword [sym.imp.USER32.dll_SetWindowTextW]
cmp byte [ebp - 0x11], 0
je 0x404a82
lea eax, [ebp - 0x60]
push eax
push ebx
call dword [sym.imp.USER32.dll_GetWindowRect]
mov eax, dword [ebp - 0x34]
cdq
sub eax, edx
mov ecx, eax
mov eax, dword [ebp - 0x60]
sar ecx, 1
sub eax, ecx
sub eax, dword [ebp - 0x4c]
push 0x64
imul eax, dword [ebp - 0x28]
cdq
pop ecx
idiv ecx
push esi
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x5c]
sub eax, edi
sub eax, dword [ebp - 0x48]
imul eax, dword [ebp - 0x24]
cdq
idiv ecx
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 0x58]
sub eax, dword [ebp - 0x60]
inc eax
imul eax, dword [ebp - 0x28]
cdq
idiv ecx
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp - 0x54]
sub eax, dword [ebp - 0x5c]
inc eax
imul eax, dword [ebp - 0x24]
cdq
idiv ecx
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x10]
push eax
push ebx
call dword [sym.imp.USER32.dll_GetClassNameW]
push 0x413338
lea eax, [ebp - 0x10]
push eax
call fcn.00404f3a
test eax, eax
jne 0x404a68
push 0xfffffffffffffff0
push ebx
call dword [sym.imp.USER32.dll_GetWindowLongW]
and al, 3
cmp al, 1
je 0x404a68
lea eax, [ebp - 0x80]
push eax
push 0
push 0x152
push ebx
call dword [sym.imp.USER32.dll_SendMessageW]
mov eax, dword [ebp - 0x74]
sub eax, dword [ebp - 0x7c]
push 0x64
inc eax
imul eax, dword [ebp - 0x24]
cdq
pop ecx
idiv ecx
add dword [ebp - 0x1c], eax
push 0x204
push dword [ebp - 0x1c]
push dword [ebp - 0x2c]
push dword [ebp - 0x30]
push dword [ebp - 0x20]
push 0
push ebx
call dword [sym.imp.USER32.dll_SetWindowPos]
push 2
push ebx
call dword [sym.imp.USER32.dll_GetWindow]
mov ebx, eax
cmp ebx, dword [ebp - 0x50]
je 0x404a9d
inc dword [ebp - 0x18]
test ebx, ebx
jne 0x404963
mov ecx, dword [ebp + 0xff0]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00406d1a
add ebp, 0xff4
leave
ret 0xc