Function at 0x402e20
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x14
mov eax, dword [ebp + 0xc]
cmp eax, 0x110
je 0x402e68
xor edi, edi
cmp eax, 0x111
jne 0x402e57
mov edi, dword [ebp + 0x10]
cmp edi, 1
je 0x402ff0
cmp dword [ebp + 0x10], 2
mov edi, 1
je 0x403198
lea esp, [ebp - 0xc]
mov eax, edi
pop ebx
pop esi
pop edi
pop ebp
ret 0x10
mov eax, dword [ebp + 0x14]
mov ebx, dword [sym.imp.user32.dll_GetDlgItem]
mov dword [esp + 4], 0x3e8
mov dword [0x40c920], eax
mov eax, dword [ebp + 8]
mov dword [esp], eax
call ebx
mov edx, dword [ebp + 0x14]
sub esp, 8
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.user32.dll_SetWindowTextW]
mov eax, dword [0x40c920]
sub esp, 8
mov esi, dword [eax + 0x208]
mov eax, dword [ebp + 8]
mov dword [esp + 4], 0x3e9
mov dword [esp], eax
and esi, 1
call ebx
sub esp, 8
mov dword [esp + 8], esi
mov esi, dword [sym.imp.user32.dll_SendMessageW]
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0xf1
mov dword [esp], eax
call esi
mov eax, dword [0x40c920]
sub esp, 0x10
mov edi, dword [eax + 0x208]
mov eax, dword [ebp + 8]
mov dword [esp + 4], 0x3ea
shr edi, 1
mov dword [esp], eax
call ebx
and edi, 1
sub esp, 8
mov dword [esp + 8], edi
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0xf1
mov dword [esp], eax
call esi
mov eax, dword [0x40c920]
sub esp, 0x10
mov edi, dword [eax + 0x208]
mov eax, dword [ebp + 8]
mov dword [esp + 4], 0x3eb
shr edi, 2
mov dword [esp], eax
call ebx
and edi, 1
sub esp, 8
mov dword [esp + 8], edi
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0xf1
mov dword [esp], eax
call esi
mov eax, dword [0x40c920]
sub esp, 0x10
mov edi, dword [eax + 0x208]
mov eax, dword [ebp + 8]
mov dword [esp + 4], 0x3ec
shr edi, 3
mov dword [esp], eax
call ebx
and edi, 1
sub esp, 8
mov dword [esp + 8], edi
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0xf1
mov dword [esp], eax
call esi
mov eax, dword [0x40c920]
sub esp, 0x10
mov edi, dword [eax + 0x208]
mov eax, dword [ebp + 8]
mov dword [esp + 4], 0x3ed
shr edi, 4
mov dword [esp], eax
call ebx
and edi, 1
sub esp, 8
mov dword [esp + 8], edi
mov edi, 1
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0xf1
mov dword [esp], eax
call esi
mov eax, edi
sub esp, 0x10
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret 0x10
mov eax, dword [ebp + 8]
mov ebx, dword [sym.imp.user32.dll_GetDlgItem]
mov dword [esp + 4], 0x3e8
mov esi, dword [0x40c920]
mov dword [esp], eax
call ebx
sub esp, 8
mov dword [esp + 4], esi
mov dword [esp + 8], 0x104
mov dword [esp], eax
call dword [sym.imp.user32.dll_GetWindowTextW]
mov eax, dword [ebp + 8]
sub esp, 0xc
mov dword [esp + 4], 0x3e9
mov dword [esp], eax
call ebx
sub esp, 8
mov dword [esp], eax
mov eax, dword [sym.imp.user32.dll_SendMessageW]
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0xf2
mov dword [ebp - 0x10], eax
call eax
mov edx, dword [ebp + 8]
sub esp, 0x10
mov esi, eax
mov dword [esp], edx
and esi, 1
mov dword [esp + 4], 0x3ea
call ebx
sub esp, 8
mov dword [esp], eax
mov eax, dword [ebp - 0x10]
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0xf2
call eax
mov edx, dword [ebp + 8]
mov ecx, esi
or ecx, 2
sub esp, 0x10
test al, 1
cmovne esi, ecx
mov dword [esp], edx
mov dword [esp + 4], 0x3eb
call ebx
sub esp, 8
mov dword [esp], eax
mov eax, dword [ebp - 0x10]
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0xf2
call eax
mov edx, dword [ebp + 8]
mov ecx, esi
or ecx, 4
sub esp, 0x10
test al, 1
cmovne esi, ecx
mov dword [esp], edx
mov dword [esp + 4], 0x3ec
call ebx
sub esp, 8
mov dword [esp], eax
mov eax, dword [ebp - 0x10]
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0xf2
call eax
mov edx, dword [ebp + 8]
mov ecx, esi
or ecx, 8
sub esp, 0x10
test al, 1
cmovne esi, ecx
mov dword [esp], edx
mov dword [esp + 4], 0x3ed
call ebx
sub esp, 8
mov dword [esp], eax
mov eax, dword [ebp - 0x10]
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0xf2
call eax
mov ecx, eax
mov eax, esi
sub esp, 0x10
or eax, 0x10
and ecx, 1
cmovne esi, eax
mov eax, dword [0x40c920]
mov dword [eax + 0x208], esi
mov eax, dword [ebp + 8]
mov dword [esp + 4], 1
mov dword [esp], eax
call dword [sym.imp.user32.dll_EndDialog]
sub esp, 8
jmp 0x402e57
mov eax, dword [ebp + 8]
mov dword [esp + 4], 2
mov dword [esp], eax
call dword [sym.imp.user32.dll_EndDialog]
sub esp, 8
jmp 0x402e57