Function at 0x40fd50
Capabilities:
Access peb ldr_data
Get ntdll base address
Get process heap flags
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
mov esi, edx
push ebx
mov ebx, eax
sub esp, 0x7c
test byte [0x413084], 8
jne 0x410140
test ebx, ebx
je 0x41017d
mov eax, dword [esi + 0xc]
test al, 8
je 0x40fd94
mov edx, dword [ebx + 0x14]
mov eax, dword [esi + 0x118]
mov ecx, dword [esi + 0x11c]
xor eax, edx
and eax, ecx
xor eax, edx
mov dword [ebx + 0x14], eax
mov eax, dword [esi + 0xc]
test al, 2
je 0x40fdcd
mov eax, dword [ebx + 8]
test eax, eax
je 0x40fdaa
mov dword [esp], eax
call sym._DestroyIcon_4
sub esp, 4
mov eax, dword [esi + 0x14]
mov dword [esp], eax
call sym._CopyIcon_4
mov dword [ebx + 8], eax
mov eax, dword [ebx + 0x20]
sub esp, 4
cmp eax, 0xffffffff
je 0x40fdca
mov edx, eax
call sym._invalidate_icons
mov eax, dword [esi + 0xc]
test al, 1
je 0x40fdda
mov eax, dword [esi + 0x10]
mov dword [ebx + 0x1c], eax
mov eax, dword [esi + 0xc]
test al, 4
je 0x40fe75
lea edi, [ebx + 0x24]
mov dword [ebp - 0x4c], edi
lea eax, [esi + 0x18]
mov edx, edi
lea edi, [esi + 0x116]
lea esi, [esi]
lea edi, [edi]
movzx ecx, word [eax]
test ecx, ecx
je 0x40fe14
mov word [edx], cx
add eax, 2
add edx, 2
cmp eax, edi
jne 0x40fe00
mov word [edx], 0
cmp dword [ebx + 0x20], 0xffffffff
je 0x40fe72
xor edx, edx
xor eax, eax
mov dword [ebp + eax - 0x44], edx
mov dword [ebp + eax - 0x40], edx
add eax, 8
cmp eax, 0x28
jb 0x40fe23
xor edx, edx
xor ecx, ecx
mov dword [ebp + eax - 0x44], edx
mov eax, dword [0x41d430]
lea edi, [ebp - 0x48]
mov dword [esp + 0xc], edi
mov edi, 0x439
mov dword [esp + 8], ecx
mov dword [esp + 4], edi
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x4c]
mov dword [ebp - 0x48], 0x30
mov dword [ebp - 0x24], eax
mov eax, dword [ebx + 0x10]
mov dword [esp], eax
call sym._SendMessageW_16
sub esp, 0x10
mov eax, dword [esi + 0xc]
test al, 0x10
je 0x40ff31
cmp dword [esi], 0x1e7
jbe 0x40ff31
lea eax, [esi + 0x120]
lea edx, [ebx + 0x124]
lea edi, [esi + 0x31e]
nop
lea esi, [esi]
movzx ecx, word [eax]
test ecx, ecx
je 0x40feb4
mov word [edx], cx
add eax, 2
add edx, 2
cmp edi, eax
jne 0x40fea0
mov word [edx], 0
lea eax, [esi + 0x324]
lea edx, [ebx + 0x324]
lea edi, [esi + 0x3a2]
nop
lea esi, [esi]
movzx ecx, word [eax]
test ecx, ecx
je 0x40fee4
mov word [edx], cx
add eax, 2
add edx, 2
cmp eax, edi
jne 0x40fed0
mov word [edx], 0
mov edx, 0x2710
mov eax, dword [esi + 0x3a4]
mov dword [ebx + 0x3a4], eax
mov eax, 0x7530
cmp dword [esi + 0x320], 0x7530
cmovbe eax, dword [esi + 0x320]
cmp eax, 0x2710
cmovb eax, edx
mov dword [ebx + 0x3a8], eax
mov eax, dword [esi + 0x3b8]
mov dword [ebx + 0x3ac], eax
mov eax, ebx
call sym._update_balloon
test byte [ebx + 0x14], 1
jne 0x410120
test byte [0x413084], 8
jne 0x4101c0
cmp dword [ebx + 0x20], 0xffffffff
jne 0x41010d
mov edx, dword [0x41d428]
mov esi, dword [0x41d42c]
mov eax, dword [0x41d424]
cmp edx, esi
jb 0x40ffc3
add esi, esi
mov edx, 0x20
cmp esi, 0x20
cmovb esi, edx
test eax, eax
lea edx, [esi*4]
je 0x410250
mov dword [esp + 0xc], edx
xor edi, edi
mov dword [esp + 8], eax
mov dword [esp + 4], edi
mov ecx, dword fs:[0x18]
mov eax, dword [ecx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_HeapReAlloc]
sub esp, 0x10
test eax, eax
je 0x41010d
mov dword [0x41d424], eax
mov edx, dword [0x41d428]
mov dword [0x41d42c], esi
mov dword [ebx + 0x20], edx
lea ecx, [edx + 1]
mov dword [eax + edx*4], ebx
mov eax, ebx
mov dword [0x41d428], ecx
call sym._update_tooltip_position
mov eax, dword [0x41d428]
dec eax
mov edx, eax
call sym._invalidate_icons
cmp dword [0x41d428], 1
je 0x410200
mov eax, dword [0x41d380]
lea edi, [ebp - 0x48]
test eax, eax
je 0x410220
xor eax, eax
mov edx, 0x80000000
mov dword [esp + 0x2c], eax
xor eax, eax
mov ecx, 0x80000000
mov dword [esp + 0x28], eax
xor eax, eax
mov esi, 0x80000001
mov dword [esp + 0x24], eax
mov eax, dword [0x41d430]
mov dword [esp + 0x14], edx
mov dword [esp + 0x10], ecx
mov dword [esp + 0xc], esi
mov dword [esp + 0x20], eax
mov eax, 0x80000000
mov dword [esp + 0x1c], eax
mov eax, 0x80000000
mov dword [esp + 0x18], eax
xor eax, eax
mov dword [esp + 8], eax
mov eax, str.tooltips_class32
mov dword [esp + 4], eax
mov dword [esp], 8
call sym._CreateWindowExW_48
xor ecx, ecx
xor edx, edx
mov dword [ebx + 0x10], eax
sub esp, 0x30
mov dword [ebp + edx - 0x44], ecx
mov dword [ebp + edx - 0x40], ecx
add edx, 8
cmp edx, 0x28
jb 0x410070
xor esi, esi
mov dword [ebp + edx - 0x44], esi
mov edx, dword [0x41d430]
mov dword [ebp - 0x48], 0x30
mov dword [ebp - 0x40], edx
lea edx, [ebx + 0x24]
mov dword [ebp - 0x24], edx
mov edx, dword [ebx + 0x20]
cmp edx, 0xffffffff
je 0x4100e8
mov esi, dword [0x41d418]
mov ecx, dword [0x41d410]
imul edx, esi
mov esi, dword [0x41d40c]
sub ecx, edx
mov edx, dword [0x41d414]
mov dword [ebp - 0x30], ecx
sub esi, edx
mov edx, esi
shr edx, 0x1f
add edx, esi
mov esi, ecx
mov ecx, dword [0x41d414]
sub esi, dword [0x41d418]
sar edx, 1
mov dword [ebp - 0x34], edx
mov dword [ebp - 0x38], esi
add edx, ecx
mov dword [ebp - 0x2c], edx
mov dword [esp + 0xc], edi
xor edx, edx
mov ecx, 0x432
mov dword [esp + 8], edx
mov dword [esp + 4], ecx
mov dword [esp], eax
call sym._SendMessageW_16
mov eax, ebx
sub esp, 0x10
call sym._update_balloon
lea esp, [ebp - 0xc]
mov ebx, 1
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, ebx
mov ebx, 1
call sym._hide_icon
lea esp, [ebp - 0xc]
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [edx + 4]
mov dword [esp + 0x14], eax
mov eax, dword [edx + 8]
mov dword [esp], 3
mov dword [esp + 0x10], eax
mov eax, str.id0x_x__hwnd_p_n
mov dword [esp + 0xc], eax
mov eax, str.modify_icon
mov dword [esp + 8], eax
mov eax, 0x413084
mov dword [esp + 4], eax
call sym._wine_dbg_log.constprop.0_4
test ebx, ebx
jne 0x40fd72
test byte [0x413084], 4
je 0x41012c
mov eax, dword [esi + 4]
mov edi, str.modify_icon
mov dword [esp + 0x14], eax
mov eax, dword [esi + 8]
mov esi, str.Invalid_icon_ID__0x_x__for_HWND__p_n
mov dword [esp + 0xc], esi
mov dword [esp + 8], edi
mov dword [esp], 2
mov dword [esp + 0x10], eax
mov eax, 0x413084
mov dword [esp + 4], eax
call sym._wine_dbg_log.constprop.0_4
jmp 0x41012c
mov eax, dword [ebx + 0xc]
mov dword [esp + 0x14], eax
mov eax, dword [ebx + 0x18]
mov dword [esp], 3
mov dword [esp + 0x10], eax
mov eax, str.id0x_x__hwnd_p_n
mov dword [esp + 0xc], eax
mov eax, str.show_icon
mov dword [esp + 8], eax
mov eax, 0x413084
mov dword [esp + 4], eax
call sym._wine_dbg_log.constprop.0_4
jmp 0x40ff48
mov eax, dword [0x41d420]
test eax, eax
jne 0x40fff3
call sym._do_show_systray
jmp 0x40fff3
mov dword [esp], edi
mov dword [ebp - 0x48], 8
mov dword [ebp - 0x44], 0x4008
call sym._InitCommonControlsEx_4
mov eax, 1
mov dword [0x41d380], eax
sub esp, 4
jmp 0x410003
mov dword [esp + 8], edx
xor edx, edx
mov dword [esp + 4], edx
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_HeapAlloc]
sub esp, 0xc
jmp 0x40ffaa