Function at 0x409f60
Capabilities:
Get keyboard layout

Disassembly:
sub esp, 0xc
push esi
push edi
mov edi, ecx
mov esi, 1
push esi
lea eax, [edi + 0x60]
push eax
call fcn.0040b3c0
push 0
mov dword [edi + 0x40], esi
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push esi
mov ecx, edi
mov dword [0x5fd764], eax
call fcn.00409150
test eax, eax
jne 0x409f9a
pop edi
pop esi
add esp, 0xc
ret 4
call fcn.00484e00
call fcn.004810b0
mov eax, dword [esp + 0x18]
mov ecx, dword [0x5dc094]
lea edx, [esp + 0xc]
mov dword [0x5d7548], ecx
push edx
push 0x4e4f14
push eax
mov dword [esp + 0x18], 0
call fcn.00441440
mov dword [0x5d754c], eax
mov eax, dword [esp + 0x18]
add esp, 0xc
test eax, eax
jne 0x409fe8
mov ecx, dword [0x5dc08c]
mov dword [0x5d754c], ecx
push ebx
mov ecx, edi
call fcn.0040b380
push esi
call fcn.0041b5c0
add esp, 4
mov ecx, edi
call fcn.0040a200
push 0x16
push str.FavoriteCY
push str.ToolBar
call fcn.004c2100
mov ecx, eax
call fcn.004c2d20
mov dword [0x5fd520], eax
call fcn.004c2100
mov dword [eax + 0x34], esi
call fcn.00438a00
mov ebx, eax
mov dword [esp + 0xc], ebx
call fcn.004808d0
mov dword [esp + 0x14], eax
call fcn.00423950
mov ecx, eax
call fcn.00423c40
call fcn.00423950
mov ecx, eax
call fcn.0042be80
call fcn.00423950
mov ecx, eax
call fcn.00425960
call fcn.00484860
cmp word [0x502a3c], 0
jne 0x40a11c
push 0x103
push 0x502a3c
push esi
mov ecx, edi
call fcn.0040ab90
lea edx, [esp + 0x1c]
test edx, edx
je 0x40a0c2
mov ecx, 0x104
mov eax, 0x502a3c
xor esi, esi
cmp word [eax], 0
je 0x40a0a4
add eax, 2
dec ecx
jne 0x40a096
jmp 0x40a0a8
test ecx, ecx
jne 0x40a0ad
mov esi, 0x80070057
test esi, esi
jl 0x40a0ba
mov edx, 0x104
sub edx, ecx
jmp 0x40a0bc
xor edx, edx
test esi, esi
jl 0x40a11c
jmp 0x40a0c6
mov edx, dword [esp + 0x1c]
mov ecx, 0x104
lea eax, [edx*2 + 0x502a3c]
sub ecx, edx
je 0x40a10e
mov ebx, str.dataIECompat.dat
lea esi, [ecx + edx + 0x7ffffefb]
sub ebx, eax
test esi, esi
je 0x40a106
mov dx, word [ebx + eax]
test dx, dx
je 0x40a106
mov word [eax], dx
add eax, 2
dec ecx
dec esi
test ecx, ecx
jne 0x40a0e4
mov ebx, dword [esp + 0xc]
sub eax, 2
jmp 0x40a117
test ecx, ecx
jne 0x40a113
mov ebx, dword [esp + 0xc]
sub eax, 2
jmp 0x40a117
mov ebx, dword [esp + 0xc]
mov word [eax], 0
push 0x502a3c
call fcn.0040df00
mov ecx, eax
call fcn.0040df30
mov eax, dword [0x5d6730]
test eax, eax
je 0x40a151
mov ecx, dword [0x5d6728]
mov edx, dword [0x5d672c]
push ecx
push edx
push eax
call fcn.00423950
mov ecx, eax
call fcn.0042a170
test ebx, ebx
je 0x40a174
mov eax, dword [esp + 0x1c]
mov ecx, edi
push eax
call fcn.0040a2b0
test eax, eax
je 0x40a16c
mov ecx, ebx
call fcn.004399e0
mov edx, dword [ebx]
push 1
mov ecx, ebx
call dword [edx]
mov eax, dword [edi + 0xc]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
pop ebx
je 0x40a18c
push eax
call esi
mov dword [edi + 0xc], 0
mov eax, dword [edi + 0x1c]
test eax, eax
je 0x40a1a7
push eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov eax, dword [edi + 0x1c]
push eax
call esi
mov dword [edi + 0x1c], 0
call fcn.00416e30
test eax, eax
je 0x40a1b8
mov edx, dword [eax]
push 1
mov ecx, eax
call dword [edx]
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x40a1c6
mov eax, dword [ecx]
push 1
call dword [eax]
mov ecx, 0x5daf68
call fcn.004b3d50
call fcn.004aa5c0
push 0
call fcn.0041b5c0
add esp, 4
mov ecx, edi
push 0
call fcn.00409150
mov edi, dword [edi + 0x10]
test edi, edi
je 0x40a1f2
push edi
call esi
pop edi
mov eax, 1
pop esi
add esp, 0xc
ret 4