Function at 0x408bf0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x4649a0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x24
push ebx
push ebp
push esi
mov ebx, ecx
xor esi, esi
push edi
mov dword [esp + 0x18], ebx
mov dword [esp + 0x2c], vtable.CMenu.0
mov dword [esp + 0x30], esi
mov dword [esp + 0x3c], esi
call fcn.00455e45
mov eax, dword [eax + 0xc]
push 0x80
push eax
call dword [sym.imp.USER32.dll_LoadMenuA]
push eax
lea ecx, [esp + 0x30]
call fcn.00441d05
mov eax, dword [0x480520]
mov dword [esp + 0x10], eax
mov ecx, dword [esp + 0x30]
mov byte [esp + 0x3c], 1
push ecx
call dword [sym.imp.USER32.dll_GetMenuItemCount]
cmp eax, esi
jbe 0x408e57
jmp 0x408c69
mov ebx, dword [esp + 0x18]
mov edx, dword [esp + 0x30]
mov ebp, dword [sym.imp.USER32.dll_GetMenuStringA]
push 0x400
push 0
push 0
push esi
push edx
call ebp
test eax, eax
jle 0x408cae
lea edi, [eax + eax + 2]
lea ecx, [esp + 0x10]
push edi
call fcn.0043d444
push 0x400
push edi
push eax
mov eax, dword [esp + 0x3c]
push esi
push eax
call ebp
push 0xffffffffffffffff
lea ecx, [esp + 0x14]
call fcn.0043d41c
jmp 0x408cb7
lea ecx, [esp + 0x10]
call fcn.0043cf28
push ecx
lea edx, [esp + 0x14]
mov ecx, esp
mov dword [esp + 0x24], esp
push edx
call fcn.0043cd12
lea eax, [esp + 0x20]
push eax
call fcn.0040a6d0
add esp, 8
mov ecx, dword [ebx + 0x1c]
mov ebp, dword [sym.imp.USER32.dll_GetMenu]
mov edi, dword [eax]
push ecx
mov byte [esp + 0x40], 2
call ebp
push eax
call fcn.00441cd2
mov edx, dword [eax + 4]
push edi
push esi
push 0x400
push esi
push edx
call dword [sym.imp.USER32.dll_ModifyMenuA]
lea ecx, [esp + 0x1c]
mov byte [esp + 0x3c], 1
call fcn.0043cf9d
mov eax, dword [ebx + 0x1c]
push eax
call ebp
push eax
call fcn.00441cd2
mov ecx, dword [eax + 4]
mov ebp, dword [sym.imp.USER32.dll_GetSubMenu]
push esi
push ecx
call ebp
push eax
call fcn.00441cd2
mov edx, dword [esp + 0x30]
mov ebx, eax
push esi
push edx
mov dword [esp + 0x1c], ebx
xor edi, edi
call ebp
push eax
call fcn.00441cd2
mov eax, dword [eax + 4]
push eax
call dword [sym.imp.USER32.dll_GetMenuItemCount]
test eax, eax
jbe 0x408e43
mov ecx, dword [ebx + 4]
push edi
push ecx
call dword [sym.imp.USER32.dll_GetMenuItemID]
mov edx, dword [ebx + 4]
push 0
push eax
push edx
mov dword [esp + 0x2c], eax
call dword [sym.imp.USER32.dll_GetMenuState]
test ah, 8
jne 0x408e22
mov eax, dword [esp + 0x30]
push esi
push eax
call ebp
push eax
call fcn.00441cd2
mov ebx, eax
push 0x400
push 0
push 0
mov ecx, dword [ebx + 4]
push edi
push ecx
call dword [sym.imp.USER32.dll_GetMenuStringA]
test eax, eax
jle 0x408dd5
lea ebp, [eax + eax + 2]
lea ecx, [esp + 0x10]
push ebp
call fcn.0043d444
mov edx, dword [ebx + 4]
push 0x400
push ebp
push eax
push edi
push edx
call dword [sym.imp.USER32.dll_GetMenuStringA]
push 0xffffffffffffffff
lea ecx, [esp + 0x14]
call fcn.0043d41c
mov ebp, dword [sym.imp.USER32.dll_GetSubMenu]
jmp 0x408dde
lea ecx, [esp + 0x10]
call fcn.0043cf28
push ecx
lea eax, [esp + 0x14]
mov ecx, esp
mov dword [esp + 0x2c], esp
push eax
call fcn.0043cd12
lea ecx, [esp + 0x28]
push ecx
call fcn.0040a6d0
mov eax, dword [eax]
mov edx, dword [esp + 0x1c]
add esp, 8
push eax
mov eax, dword [esp + 0x24]
push eax
push 0
push eax
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.USER32.dll_ModifyMenuA]
lea ecx, [esp + 0x24]
call fcn.0043cf9d
mov ebx, dword [esp + 0x14]
mov ecx, dword [esp + 0x30]
push esi
push ecx
inc edi
call ebp
push eax
call fcn.00441cd2
mov edx, dword [eax + 4]
push edx
call dword [sym.imp.USER32.dll_GetMenuItemCount]
cmp edi, eax
jb 0x408d55
mov eax, dword [esp + 0x30]
inc esi
push eax
call dword [sym.imp.USER32.dll_GetMenuItemCount]
cmp esi, eax
jb 0x408c65
lea ecx, [esp + 0x2c]
call fcn.00441d5c
lea ecx, [esp + 0x10]
mov byte [esp + 0x3c], 0
call fcn.0043cf9d
mov dword [esp + 0x2c], vtable.CMenu.0
lea ecx, [esp + 0x2c]
mov dword [esp + 0x3c], 3
call fcn.00441d5c
mov ecx, dword [esp + 0x34]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x30
ret