Function at 0x476960
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x525ff6
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xa0
push ebx
push ebp
push esi
mov esi, ecx
mov ecx, dword [esp + 0xbc]
lea eax, [ecx + 0xac]
mov edx, dword [eax]
push edi
mov edi, dword [eax + 4]
mov dword [esp + 0x7c], edx
mov edx, dword [eax + 8]
mov eax, dword [eax + 0xc]
mov dword [esp + 0x74], esi
mov dword [esp + 0x80], edi
mov dword [esp + 0x84], edx
mov dword [esp + 0x88], eax
call fcn.00500163
mov ebp, dword [esi + 0x58]
mov edx, eax
and edx, 0x80
xor ebx, ebx
xor ecx, ecx
cmp ebp, ebx
mov dword [esp + 0x78], edx
jle 0x476a12
cmp ecx, ebx
jl 0x476db7
cmp ecx, dword [esi + 0x58]
jge 0x476db7
mov eax, dword [esi + 0x54]
lea eax, [eax + ecx*4]
mov eax, dword [eax]
cmp edi, dword [eax]
jne 0x4769f4
cmp edx, dword [eax + 4]
je 0x4769fb
inc ecx
cmp ecx, ebp
jl 0x4769d2
jmp 0x476a12
mov ecx, dword [eax + 0x20]
mov ebp, dword [eax + 0x18]
mov edi, dword [esp + 0xc4]
add ecx, ebp
cmp edi, ecx
jge 0x476e38
xor eax, eax
cmp edx, ebx
setne al
push ecx
mov ecx, esp
mov dword [esp + 0x38], esp
push str.WINDOW
inc eax
mov ebp, eax
mov dword [esp + 0x20], ebp
call fcn.00402aa0
mov ecx, dword [esi + 0x24]
mov edx, dword [ecx]
call dword [edx + 4]
push ebx
push 0xbb9
push 1
mov edi, eax
push ebp
lea eax, [esp + 0x20]
push eax
mov ecx, edi
call fcn.00447210
mov eax, dword [esp + 0x10]
cmp dword [eax - 0xc], ebx
mov dword [esp + 0xb8], ebx
je 0x476ac1
mov ecx, dword [esi + 0x24]
mov edx, dword [ecx + 0x3c]
mov ecx, dword [edi + 0x10]
push eax
push edx
lea edx, [esp + 0x54]
push edx
call fcn.004797f0
mov edx, dword [esp + 0x4c]
xor eax, eax
cmp edx, eax
mov ecx, ebx
jne 0x476a87
cmp dword [esp + 0x50], ecx
je 0x476abd
mov eax, dword [esi + 0x24]
mov edx, dword [esp + 0x10]
mov eax, dword [eax + 0x3c]
mov ecx, dword [edi + 0x10]
push edx
push eax
call fcn.00479780
cmp eax, ebx
mov dword [esp + 0x38], eax
je 0x476abd
push 1
push 0x961
push 1
push ebp
mov ecx, edi
call fcn.00446c80
cmp eax, 1
mov dword [esp + 0x14], eax
jge 0x476aed
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
mov dword [esp + 0xb8], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x476ae6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
xor eax, eax
jmp 0x476e38
push 0x30
call fcn.00500fa3
add esp, 4
cmp eax, ebx
je 0x476b10
mov ecx, vtable.CRgn.0
mov dword [eax + 0xc], ebx
mov dword [eax + 8], ecx
mov dword [eax + 0x14], ebx
mov dword [eax + 0x10], ecx
mov esi, eax
jmp 0x476b12
xor esi, esi
lea ebp, [esi + 0x18]
push ebp
mov dword [esi + 0x2c], ebx
call dword [sym.imp.USER32.dll_SetRectEmpty]
mov eax, dword [esp + 0xc0]
push eax
lea ecx, [esp + 0xa0]
call fcn.00505b33
lea ecx, [esp + 0x64]
mov byte [esp + 0xb8], 1
call fcn.00505517
mov ecx, dword [esp + 0xa0]
push ecx
mov byte [esp + 0xbc], 2
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push eax
lea ecx, [esp + 0x68]
call fcn.005059ff
mov eax, dword [esp + 0x50]
cdq
idiv dword [esp + 0x14]
mov ecx, dword [esp + 0x4c]
mov dword [esp + 0x8c], ebx
mov dword [esp + 0x90], ebx
mov dword [esp + 0x94], ecx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ecx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x2c], vtable.CBitmap.0
mov dword [esp + 0x98], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 0x28], eax
mov edx, dword [esp + 0xa0]
push eax
push ecx
push edx
mov byte [esp + 0xc4], 3
call dword [sym.imp.GDI32.dll_CreateCompatibleBitmap]
push eax
lea ecx, [esp + 0x30]
call fcn.00505cfc
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x68]
push eax
push ecx
call fcn.00505d85
mov ecx, dword [esp + 0x38]
mov dword [esp + 0x34], eax
call fcn.00478710
test eax, eax
je 0x476bf6
xor eax, eax
jmp 0x476c0a
mov edx, dword [esp + 0x18]
push ebx
push 0x899
push 1
push edx
mov ecx, edi
call fcn.00446cb0
cmp eax, ebx
mov dword [esp + 0x14], 0xffffffff
je 0x476c37
mov eax, dword [esp + 0x18]
push 0xff00ff
push 0xee1
push 1
push eax
mov ecx, edi
call fcn.00446ce0
cmp eax, 0xffffffff
mov dword [esp + 0x14], eax
jne 0x476c3c
mov eax, 0xff00ff
push eax
lea ecx, [esp + 0x20]
push ecx
lea ecx, [esp + 0x6c]
call fcn.00512db1
sub esp, 0x10
mov ebx, esp
xor eax, eax
mov dword [ebx], eax
xor ecx, ecx
mov dword [ebx + 4], ecx
xor edx, edx
push 0xe11
mov dword [ebx + 8], edx
mov edx, dword [esp + 0x2c]
push 1
mov dword [ebx + 0xc], eax
push edx
lea eax, [esp + 0x58]
push eax
mov ecx, edi
call fcn.00446c20
mov ecx, dword [esp + 0x20]
mov eax, dword [esp + 0x28]
mov edx, dword [esp + 0x40]
sub eax, ecx
mov ecx, dword [esp + 0x48]
lea edi, [ecx + edx]
cmp edi, eax
jle 0x476ca3
sub eax, edx
mov ecx, 0
sets cl
dec ecx
and ecx, eax
mov dword [esp + 0x48], ecx
mov eax, dword [esp + 0x3c]
mov edi, dword [esp + 0x44]
mov ebx, eax
mov dword [esp + 0x60], ecx
lea ecx, [edi + eax]
mov eax, dword [esp + 0xc4]
cmp eax, ecx
mov dword [esp + 0x54], ebx
mov dword [esp + 0x58], edx
mov dword [esp + 0x5c], edi
jge 0x476d0d
mov dword [esp + 0x24], eax
mov dword [esi + 0x2c], 1
mov eax, dword [esp + 0x3c]
mov edx, dword [esp + 0x44]
mov edi, dword [esp + 0x1c]
add edx, eax
push edx
push eax
mov eax, dword [esp + 0x2c]
sub eax, edi
push eax
call dword [sym.imp.KERNEL32.dll_MulDiv]
mov edi, dword [esp + 0x24]
mov ecx, dword [esp + 0x3c]
mov ebx, eax
mov eax, dword [esp + 0x1c]
sub edi, ecx
sub edi, eax
mov dword [esp + 0x54], ebx
mov dword [esp + 0x5c], edi
mov ecx, dword [esp + 0x14]
push 0
push 1
push ecx
lea edx, [esp + 0x48]
push edx
lea eax, [esp + 0x9c]
push eax
lea ecx, [esp + 0x30]
push ecx
mov ecx, dword [esp + 0x50]
lea edx, [esp + 0x7c]
push edx
call fcn.004794e0
mov eax, dword [esp + 0x14]
cmp eax, 0xffffffff
jne 0x476d44
mov eax, 0xff00ff
push eax
lea eax, [esp + 0x58]
push eax
lea ecx, [esp + 0x24]
push ecx
lea edx, [esi + 0x28]
push edx
lea eax, [esi + 0x10]
push eax
lea ecx, [esi + 8]
push ecx
lea edx, [esp + 0x7c]
push edx
call fcn.00473fc0
mov eax, dword [esp + 0x50]
add esp, 0x1c
test eax, eax
je 0x476d73
mov eax, dword [eax + 4]
push eax
mov eax, dword [esp + 0x6c]
push eax
call fcn.00505d85
mov eax, dword [esp + 0x78]
mov ecx, dword [esp + 0x58]
mov edx, dword [esp + 0x60]
mov dword [ebp], ebx
mov dword [ebp + 4], ecx
mov ecx, dword [esp + 0x80]
mov dword [esi + 4], eax
mov eax, dword [esi + 0x2c]
test eax, eax
mov dword [ebp + 8], edi
mov dword [ebp + 0xc], edx
mov dword [esi], ecx
jne 0x476dcf
mov edi, dword [esp + 0x74]
mov ebx, dword [edi + 0x58]
add edi, 0x50
test ebx, ebx
jge 0x476dbc
call fcn.004f96a8
push 0xffffffffffffffff
lea edx, [ebx + 1]
push edx
mov ecx, edi
call fcn.004d5e00
mov eax, dword [edi + 4]
mov dword [eax + ebx*4], esi
lea ecx, [esp + 0x2c]
mov byte [esp + 0xb8], 2
mov dword [esp + 0x2c], vtable.CGdiObject.0
call fcn.00505d53
lea ecx, [esp + 0x64]
mov byte [esp + 0xb8], 1
call fcn.00505a7d
lea ecx, [esp + 0x9c]
mov byte [esp + 0xb8], 0
call fcn.00505b8e
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
mov dword [esp + 0xb8], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x476e36
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, esi
mov ecx, dword [esp + 0xb0]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0xac
ret 0xc