Function at 0x4038ca
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
push esi
push edi
push dword [0x40fb48]
call fcn.0040b46b
mov ebp, eax
call fcn.0040aa19
call fcn.004040f8
xor edi, edi
cmp dword [0x40f940], edi
jne 0x403a49
mov esi, 0xa4
push esi
push edi
push 0x40f948
call sub.MSVCRT.dll_memset
add esp, 0xc
mov dword [0x40f94c], esi
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [0x40f948], 0x16
mov dword [0x40f950], 0x4035fb
push str.RICHED20.DLL
mov dword [0x40f968], 0x40351b
mov dword [0x40f960], 0x403899
mov dword [0x40f964], 0x403db5
mov dword [0x40f97c], 0x403642
mov dword [0x40f974], 0x403628
mov dword [0x40f970], 0x403b90
mov dword [0x40f988], 0x40382a
mov dword [0x40f98c], 0x403d35
mov dword [0x40f9b0], 0x4037ad
mov dword [0x40f9b4], 0x403c13
mov dword [0x40f9c4], 0x4037fa
mov dword [0x40f9c0], 0x403c76
mov dword [0x40f9e0], 0x403820
mov dword [0x40f9e4], 0x403d10
call esi
mov dword [0x40f944], eax
test eax, eax
jne 0x4039c9
push str.RICHED32.DLL
call esi
mov eax, dword [0x40f938]
test eax, eax
je 0x403a3f
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.OpenThemeData
push eax
call esi
push str.CloseThemeData
push dword [0x40f938]
mov dword [0x40f9f0], eax
call esi
push str.GetThemeBackgroundContentRect
push dword [0x40f938]
mov dword [0x40f9f4], eax
call esi
push str.IsThemeBackgroundPartiallyTransparent
push dword [0x40f938]
mov dword [0x40f9f8], eax
call esi
push str.DrawThemeParentBackground
push dword [0x40f938]
mov dword [0x40f9fc], eax
call esi
push str.DrawThemeBackground
push dword [0x40f938]
mov dword [0x40fa00], eax
call esi
mov dword [0x40fa04], eax
mov dword [0x40f940], 1
mov ecx, dword [0x40f934]
mov edx, str.RichEdit20W
neg ecx
sbb ecx, ecx
and ecx, 0xfffffe00
add ecx, 0x200
cmp dword [0x40f944], edi
jne 0x403a71
mov edx, str.RichEdit
mov eax, dword [esp + 0x24]
or esi, 0xffffffff
push edi
push dword [0x40f660]
or eax, 0x503111c4
push esi
push dword [ebp]
push dword [esp + 0x30]
push dword [esp + 0x30]
push dword [esp + 0x30]
push dword [esp + 0x30]
push eax
push edi
push edx
push ecx
call dword [sym.imp.USER32.DLL_CreateWindowExW]
mov edi, eax
test edi, edi
je 0x403b66
push ebx
push dword [esp + 0x14]
push dword [0x40fb64]
call fcn.0040b4fc
mov ebx, eax
push 0x10
push 8
mov dword [ebx + 0x18], esi
mov dword [ebx + 0x14], esi
mov ecx, dword [ebp + 8]
mov dword [ebx + 0x1c], ecx
push dword [0x40f65c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push eax
push str.PB_ClientRect
push edi
call dword [sym.imp.USER32.DLL_SetPropW]
xor ebp, ebp
push ebp
push esi
mov esi, dword [sym.imp.USER32.DLL_SendMessageW]
push 0xc5
push edi
call esi
push 0x40366d
push 0xfffffffffffffffc
push edi
call dword [sym.imp.USER32.DLL_SetWindowLongW]
push 0x37
push ebp
push ebp
push ebp
push ebp
push ebp
push edi
mov dword [0x40f9ec], eax
call dword [sym.imp.USER32.DLL_SetWindowPos]
push 0x541
push ebp
push ebp
push edi
call dword [sym.imp.USER32.DLL_RedrawWindow]
push ebp
push ebp
push 0x43b
push edi
call esi
or eax, 1
push eax
push ebp
push 0x445
push edi
call esi
push 0x40f948
push edi
push ebx
push dword [esp + 0x20]
call fcn.00404332
mov edi, eax
mov eax, 0x10000000
test dword [esp + 0x28], eax
je 0x403b65
push 1
push eax
push ebx
call fcn.00403c13
pop ebx
call fcn.0040aa28
mov eax, edi
pop edi
pop esi
pop ebp
ret 0x18