Function at 0x404e88
Capabilities:
Get graphical window text
Read .ini file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4b8
push ebx
push esi
push edi
push edx
push ecx
mov dword [ebp - 0x18], ecx
call dword [sym.imp.USER32.dll_GetDlgItem]
xor esi, esi
mov edi, eax
cmp dword [ebp + 8], esi
jne 0x404ebd
lea eax, [ebp - 0x30]
push 0x41cc20
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x30]
mov dword [ebp + 8], eax
mov ebx, 0x200
lea eax, [ebp - 0x2b8]
push ebx
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowTextA]
lea edx, [ebp - 0x2b8]
lea ecx, [ebp - 0x4b8]
call fcn.0040512d
lea eax, [ebp - 0x14]
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowRect]
push edi
call dword [sym.imp.USER32.dll_GetDC]
mov dword [ebp - 4], eax
push esi
push esi
push 0x31
push edi
call dword [sym.imp.USER32.dll_SendMessageA]
push eax
push dword [ebp - 4]
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x38]
push eax
lea eax, [ebp - 0x4b8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
lea eax, [ebp - 0x4b8]
push eax
push dword [ebp - 4]
call dword [sym.imp.GDI32.dll_GetTextExtentPoint32A]
mov esi, dword [sym.imp.USER32.dll_GetWindowLongA]
push 0xffffffffffffffec
push edi
call esi
test eax, 0x400000
je 0x404f5d
push 1
pop eax
cmp dword [ebp + 0x10], eax
jne 0x404f54
mov dword [ebp + 0x10], 3
jmp 0x404f5d
cmp dword [ebp + 0x10], 3
jne 0x404f5d
mov dword [ebp + 0x10], eax
lea eax, [ebp - 0xb8]
push 0x80
push eax
push edi
call dword [sym.imp.USER32.dll_GetClassNameA]
lea eax, [ebp - 0xb8]
push 0x418458
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x404f91
push 0xfffffffffffffff0
push edi
call esi
and eax, 0xf
mov dword [ebp - 0x28], eax
mov esi, dword [ebp - 0xc]
push 0x41cc30
sub esi, dword [ebp - 0x14]
lea eax, [ebp - 0x2b8]
push ebx
push eax
push dword [ebp + 8]
sub esi, dword [ebp - 0x38]
push dword [ebp + 0xc]
push 0x41cd38
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
cmp byte [ebp - 0x2b8], 0
je 0x404fd1
lea eax, [ebp - 0x2b8]
push eax
push edi
call dword [sym.imp.USER32.dll_SetWindowTextA]
jmp 0x404fe0
lea eax, [ebp - 0x2b8]
push ebx
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowTextA]
cmp dword [ebp + 0x10], 0
je 0x405105
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenA]
lea eax, [ebp - 0x2b8]
push eax
call ebx
test eax, eax
je 0x405105
test esi, esi
jge 0x405007
xor esi, esi
lea edx, [ebp - 0x2b8]
lea ecx, [ebp - 0x4b8]
call fcn.0040512d
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x4b8]
push eax
call ebx
push eax
lea eax, [ebp - 0x4b8]
push eax
push dword [ebp - 4]
call dword [sym.imp.GDI32.dll_GetTextExtentPoint32A]
lea eax, [ebp - 0xb8]
push 0x418458
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x405073
mov eax, dword [ebp - 0x28]
cmp eax, 2
je 0x405070
cmp eax, 3
je 0x405070
cmp eax, 4
je 0x40506c
cmp eax, 9
je 0x40506c
cmp esi, 0xa
jge 0x405073
push 0xa
jmp 0x405072
push 0x14
jmp 0x405072
push 0x1c
pop esi
lea eax, [ebp - 0x14]
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowRect]
lea eax, [ebp - 0x14]
xor ebx, ebx
push 2
push eax
push dword [ebp - 0x18]
push ebx
call dword [sym.imp.USER32.dll_MapWindowPoints]
cmp dword [ebp + 0x10], 1
jne 0x4050a9
mov eax, dword [ebp - 8]
push 6
sub eax, dword [ebp - 0x10]
push eax
mov eax, dword [ebp - 0x20]
add eax, esi
push eax
push ebx
push ebx
jmp 0x4050fd
cmp dword [ebp + 0x10], 3
jne 0x4050cb
mov eax, dword [ebp - 8]
push 4
sub eax, dword [ebp - 0x10]
push eax
mov eax, dword [ebp - 0x20]
lea ecx, [eax + esi]
push ecx
mov ecx, dword [ebp - 0xc]
push dword [ebp - 0x10]
sub ecx, eax
sub ecx, esi
jmp 0x4050fc
cmp dword [ebp + 0x10], 2
jne 0x405105
mov eax, dword [ebp - 0x20]
push 4
add esi, eax
mov eax, dword [ebp - 8]
sub eax, dword [ebp - 0x10]
push eax
mov eax, dword [ebp - 0xc]
sub eax, dword [ebp - 0x14]
push esi
push dword [ebp - 0x10]
cdq
sub eax, edx
mov ecx, eax
mov eax, esi
cdq
sub eax, edx
sar ecx, 1
sar eax, 1
sub ecx, eax
add ecx, dword [ebp - 0x14]
push ecx
push ebx
push edi
call dword [sym.imp.USER32.dll_SetWindowPos]
push dword [ebp - 0x24]
push dword [ebp - 4]
call dword [sym.imp.GDI32.dll_SelectObject]
push dword [ebp - 4]
push edi
call dword [sym.imp.USER32.dll_ReleaseDC]
xor eax, eax
cmp byte [ebp - 0x4b8], al
pop edi
pop esi
pop ebx
setne al
leave
ret 0xc