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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x7c
push ebx
push esi
mov esi, ecx
cmp dword [esi + 0x4c], 0
push edi
mov dword [esp + 0x20], esi
je 0x476583
lea edi, [esi + 4]
push edi
call dword [sym.imp.USER32.dll_IsRectEmpty]
test eax, eax
jne 0x476583
push edi
lea eax, [esp + 0x4c]
push eax
call dword [sym.imp.USER32.dll_CopyRect]
push dword [ebp + 0x10]
lea eax, [esp + 0x4c]
push dword [ebp + 0xc]
push eax
call dword [sym.imp.USER32.dll_OffsetRect]
mov eax, dword [esi + 0x64]
test al, 1
je 0x475e0b
push dword [esi + 0x100]
jmp 0x475e15
test al, 2
je 0x475e33
push dword [esi + 0x104]
call dword [sym.imp.GDI32.dll_CreateSolidBrush]
mov edi, eax
push edi
lea eax, [esp + 0x4c]
push eax
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_FillRect]
push edi
call dword [sym.imp.GDI32.dll_DeleteObject]
mov ecx, dword [esi + 0xb8]
add dword [esp + 0x4c], ecx
mov ecx, dword [esp + 0x50]
mov eax, dword [esp + 0x48]
add eax, dword [esi + 0xb4]
sub ecx, dword [esi + 0xbc]
mov edx, dword [esi + 0xc0]
sub dword [esp + 0x54], edx
mov edi, dword [sym.imp.USER32.dll_SetRect]
mov dword [esp + 0x50], ecx
sub ecx, eax
mov dword [esp + 0x48], eax
mov eax, dword [esi + 0xd4]
mov dword [esp + 0x1c], ecx
test eax, eax
je 0x475f33
call fcn.00470d58
mov ecx, dword [eax]
mov eax, dword [eax + 4]
mov dword [esp + 0x44], eax
mov eax, ecx
cdq
and edx, 3
add eax, edx
mov ebx, eax
sar ebx, 2
test byte [esi + 0x64], 3
je 0x475f26
mov ecx, dword [esp + 0x50]
mov eax, ecx
sub eax, dword [esp + 0x48]
cmp eax, ebx
jl 0x475f26
mov eax, dword [esp + 0x54]
sub eax, dword [esp + 0x44]
sub eax, dword [esp + 0x4c]
cdq
sub eax, edx
mov edx, dword [esp + 0x44]
sar eax, 1
add eax, dword [esp + 0x4c]
add edx, eax
push edx
lea edx, [ecx - 1]
push edx
push eax
sub ecx, ebx
dec ecx
push ecx
lea eax, [esi + 0xe8]
push eax
call edi
mov ecx, dword [esi + 0xf8]
xor eax, eax
test cl, 2
je 0x475eee
inc eax
jmp 0x475ef6
test cl, 1
je 0x475ef6
push 2
pop eax
push 0
imul eax, ebx
push dword [esp + 0x48]
push ebx
mov ebx, dword [esi + 0xd4]
push 0
push eax
push 0xa
lea eax, [esi + 0xe8]
push eax
push dword [ebp + 8]
call fcn.0047099a
mov eax, dword [esi + 0xe8]
mov dword [esp + 0x50], eax
jmp 0x475f33
lea eax, [esi + 0xe8]
push eax
call dword [sym.imp.USER32.dll_SetRectEmpty]
cmp dword [esi + 0x30], 0xffffffff
je 0x475f8e
mov eax, dword [esp + 0x50]
mov ecx, dword [esp + 0x48]
sub eax, ecx
cmp eax, 0x10
jl 0x47609d
mov eax, dword [esp + 0x54]
sub eax, dword [esp + 0x4c]
lea ebx, [esi + 0xd8]
sub eax, 0x10
cdq
sub eax, edx
sar eax, 1
add eax, dword [esp + 0x4c]
lea edx, [eax + 0x10]
push edx
lea edx, [ecx + 0x17]
push edx
push eax
add ecx, 7
push ecx
push ebx
call edi
push dword [ebp + 8]
call fcn.00490a11
push eax
mov eax, dword [esi + 0x30]
mov edi, ebx
call fcn.00490a4d
jmp 0x47609d
mov eax, dword [esi + 0x34]
test eax, eax
je 0x476032
mov ecx, dword [esi + 0x64]
and dword [esp + 0x14], 0
mov edx, ecx
shr edx, 0x10
not edx
test dl, 1
jne 0x475fb5
push 3
pop edx
cmp dword [esi + 0x38], edx
ja 0x475fc2
test cl, 2
je 0x475fc8
xor edx, edx
inc edx
cmp dword [esi + 0x38], edx
jbe 0x475fc8
mov dword [esp + 0x14], edx
jmp 0x475fd9
test cl, 1
je 0x475fd9
push 2
pop ecx
cmp dword [esi + 0x38], ecx
jbe 0x475fd9
mov dword [esp + 0x14], ecx
call fcn.00470d58
mov edx, dword [eax]
mov ecx, dword [eax + 4]
mov eax, edx
xor edx, edx
div dword [esi + 0x38]
mov ebx, eax
mov eax, dword [esp + 0x54]
sub eax, ecx
sub eax, dword [esp + 0x4c]
cdq
sub eax, edx
sar eax, 1
add eax, dword [esp + 0x4c]
add ecx, eax
push ecx
mov ecx, dword [esp + 0x4c]
lea edx, [ebx + ecx + 7]
push edx
push eax
add ecx, 7
push ecx
lea eax, [esi + 0xd8]
push eax
call edi
xor eax, eax
imul ebx, dword [esp + 0x14]
push eax
push eax
push eax
push eax
push ebx
mov ebx, dword [esi + 0x34]
push eax
lea eax, [esi + 0xd8]
push eax
jmp 0x476095
mov eax, dword [0x5497fc]
test eax, eax
je 0x47609d
call fcn.00470d58
mov edx, dword [eax]
mov ecx, dword [eax + 4]
mov eax, dword [esp + 0x50]
sub eax, dword [esp + 0x48]
mov dword [esp + 0x40], edx
cmp eax, edx
jl 0x47609d
mov eax, dword [esp + 0x54]
sub eax, ecx
sub eax, dword [esp + 0x4c]
lea ebx, [esi + 0xd8]
cdq
sub eax, edx
mov edx, dword [esp + 0x40]
sar eax, 1
add eax, dword [esp + 0x4c]
add ecx, eax
push ecx
mov ecx, dword [esp + 0x4c]
lea edx, [edx + ecx + 7]
push edx
push eax
add ecx, 7
push ecx
push ebx
call edi
xor eax, eax
push eax
push eax
push eax
push eax
push eax
push eax
push ebx
mov ebx, dword [0x5497fc]
push dword [ebp + 8]
call fcn.0047099a
add dword [esp + 0x48], 0x20
dec dword [esp + 0x50]
dec dword [esp + 0x54]
lea eax, [esi + 0xe8]
push eax
mov dword [esp + 0x44], eax
call dword [sym.imp.USER32.dll_IsRectEmpty]
test eax, eax
je 0x4760c4
sub dword [esp + 0x50], 0xa
mov eax, dword [esp + 0x48]
add eax, 0xb
cmp eax, dword [esp + 0x50]
jge 0x476560
mov eax, dword [esi + 0x98]
xor edi, edi
mov dword [esp + 0x28], edi
cmp eax, edi
je 0x4760f3
push eax
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x28], eax
push 1
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SetBkMode]
mov eax, dword [esi + 0x64]
and eax, 1
je 0x47610e
mov ecx, dword [esi + 0xa0]
jmp 0x476114
mov ecx, dword [esi + 0xa8]
cmp eax, edi
je 0x476120
mov edx, dword [esi + 0xa0]
jmp 0x476126
mov edx, dword [esi + 0xac]
mov dword [esp + 0x24], edx
cmp eax, edi
je 0x476134
mov dword [esp + 0x2c], ecx
jmp 0x47613e
mov edx, dword [esi + 0x108]
mov dword [esp + 0x2c], edx
cmp eax, edi
mov eax, dword [esp + 0x24]
jne 0x47614c
mov eax, dword [esi + 0x108]
push ecx
push dword [ebp + 8]
mov dword [esp + 0x3c], eax
call dword [sym.imp.GDI32.dll_SetTextColor]
cmp dword [esp + 0x1c], 0xfa
mov dword [esp + 0x3c], eax
jge 0x47616e
mov eax, dword [esp + 0x1c]
jmp 0x47617f
mov eax, dword [esi + 0xd0]
imul eax, dword [esp + 0x1c]
push 0x64
cdq
pop ecx
idiv ecx
mov ecx, dword [esp + 0x48]
add eax, ecx
cmp eax, dword [esp + 0x50]
jl 0x47618f
mov eax, dword [esp + 0x50]
mov ebx, dword [sym.imp.USER32.dll_DrawTextW]
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x54]
mov dword [esp + 0x58], ecx
mov ecx, dword [esp + 0x4c]
mov dword [esp + 0x64], eax
mov eax, dword [esi + 0x1c]
mov dword [esp + 0x5c], ecx
mov dword [esp + 0x10], eax
lea eax, [esi + 0x110]
mov ecx, dword [eax + 0x10]
sub ecx, dword [eax + 0xc]
mov dword [esp + 0xc], edi
sar ecx, 2
mov dword [esp + 0x18], edi
mov dword [esp + 0x30], eax
test ecx, ecx
jbe 0x476330
mov edi, dword [esp + 0x18]
mov esi, eax
call fcn.0044a99d
mov eax, dword [eax]
mov edi, dword [esp + 0xc]
mov esi, eax
xor ecx, ecx
movzx eax, ax
shr esi, 0x10
mov dword [esp + 0x14], eax
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x70], ecx
mov dword [esp + 0x74], ecx
cmp edi, esi
jae 0x476262
mov eax, dword [esp + 0x10]
mov dword [esp + 0xc], esi
sub dword [esp + 0xc], edi
push 0xc24
lea edi, [eax + edi*2]
lea eax, [esp + 0x6c]
push eax
push dword [esp + 0x14]
push edi
push dword [ebp + 8]
call ebx
push 0x40824
lea eax, [esp + 0x5c]
push eax
push dword [esp + 0x14]
push edi
push dword [ebp + 8]
call ebx
mov eax, dword [esp + 0x70]
sub eax, dword [esp + 0x68]
add dword [esp + 0x58], eax
lea eax, [esp + 0x68]
push eax
call dword [sym.imp.USER32.dll_SetRectEmpty]
mov dword [esp + 0xc], esi
mov edi, esi
xor ecx, ecx
jmp 0x476277
lea edx, [eax + esi]
cmp edx, edi
jbe 0x476273
sub esi, edi
add eax, esi
mov dword [esp + 0x14], eax
jmp 0x476277
mov dword [esp + 0x14], ecx
mov eax, dword [esp + 0x20]
mov eax, dword [eax + 0x10c]
mov dword [esp + 0x1c], ecx
cmp eax, ecx
je 0x476297
push eax
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x1c], eax
push dword [esp + 0x2c]
mov esi, dword [sym.imp.GDI32.dll_SetTextColor]
push dword [ebp + 8]
call esi
push 0xc24
lea ecx, [esp + 0x6c]
push ecx
push dword [esp + 0x1c]
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0x1c]
lea eax, [eax + edi*2]
push eax
push dword [ebp + 8]
mov dword [esp + 0x20], eax
call ebx
push 0x40824
lea eax, [esp + 0x5c]
push eax
push dword [esp + 0x1c]
push dword [esp + 0x18]
push dword [ebp + 8]
call ebx
cmp dword [esp + 0x1c], 0
je 0x4762f4
push dword [esp + 0x1c]
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SelectObject]
push dword [esp + 0x38]
push dword [ebp + 8]
call esi
mov eax, dword [esp + 0x70]
sub eax, dword [esp + 0x68]
add edi, dword [esp + 0x14]
add dword [esp + 0x58], eax
mov eax, dword [esp + 0x30]
mov ecx, dword [eax + 0x10]
sub ecx, dword [eax + 0xc]
inc dword [esp + 0x18]
sar ecx, 2
mov dword [esp + 0xc], edi
cmp dword [esp + 0x18], ecx
jb 0x4761d7
mov esi, dword [esp + 0x20]
mov ecx, dword [esp + 0xc]
push 0x40824
lea eax, [esp + 0x5c]
push eax
mov eax, dword [esp + 0x18]
push 0xffffffffffffffff
lea eax, [eax + ecx*2]
push eax
push dword [ebp + 8]
call ebx
mov eax, dword [esp + 0x60]
add eax, 0xa
cmp eax, dword [esp + 0x50]
jge 0x47653f
push dword [esp + 0x24]
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SetTextColor]
mov eax, dword [esp + 0x60]
and dword [esp + 0xc], 0
and dword [esp + 0x1c], 0
add eax, 0xa
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x7c], eax
mov eax, dword [esp + 0x50]
mov dword [esp + 0x80], eax
mov eax, dword [esp + 0x54]
mov dword [esp + 0x84], eax
mov eax, dword [esi + 0xcc]
mov dword [esp + 0x10], eax
lea eax, [esi + 0x128]
mov ecx, dword [eax + 0x10]
sub ecx, dword [eax + 0xc]
mov dword [esp + 0x30], eax
sar ecx, 2
test ecx, ecx
jbe 0x476522
jmp 0x4763c9
mov eax, dword [esp + 0x30]
mov edi, dword [esp + 0x1c]
mov esi, eax
call fcn.0044a99d
mov eax, dword [eax]
mov edi, dword [esp + 0xc]
mov esi, eax
xor ecx, ecx
movzx eax, ax
shr esi, 0x10
mov dword [esp + 0x14], eax
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x70], ecx
mov dword [esp + 0x74], ecx
cmp edi, esi
jae 0x476454
mov eax, dword [esp + 0x10]
mov dword [esp + 0x18], esi
sub dword [esp + 0x18], edi
push 0xc24
lea edi, [eax + edi*2]
lea eax, [esp + 0x6c]
push eax
push dword [esp + 0x20]
push edi
push dword [ebp + 8]
call ebx
push 0x40824
lea eax, [esp + 0x7c]
push eax
push dword [esp + 0x20]
push edi
push dword [ebp + 8]
call ebx
mov eax, dword [esp + 0x70]
sub eax, dword [esp + 0x68]
add dword [esp + 0x78], eax
lea eax, [esp + 0x68]
push eax
call dword [sym.imp.USER32.dll_SetRectEmpty]
mov dword [esp + 0xc], esi
mov edi, esi
xor ecx, ecx
jmp 0x476469
lea edx, [eax + esi]
cmp edx, edi
jbe 0x476465
sub esi, edi
add eax, esi
mov dword [esp + 0x14], eax
jmp 0x476469
mov dword [esp + 0x14], ecx
mov eax, dword [esp + 0x20]
mov eax, dword [eax + 0x10c]
mov dword [esp + 0x24], ecx
cmp eax, ecx
je 0x476489
push eax
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x24], eax
push dword [esp + 0x34]
mov esi, dword [sym.imp.GDI32.dll_SetTextColor]
push dword [ebp + 8]
call esi
push 0xc24
lea ecx, [esp + 0x6c]
push ecx
push dword [esp + 0x1c]
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0x1c]
lea eax, [eax + edi*2]
push eax
push dword [ebp + 8]
mov dword [esp + 0x20], eax
call ebx
push 0x40824
lea eax, [esp + 0x7c]
push eax
push dword [esp + 0x1c]
push dword [esp + 0x18]
push dword [ebp + 8]
call ebx
cmp dword [esp + 0x24], 0
je 0x4764e6
push dword [esp + 0x24]
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SelectObject]
push dword [esp + 0x38]
push dword [ebp + 8]
call esi
mov eax, dword [esp + 0x70]
sub eax, dword [esp + 0x68]
add edi, dword [esp + 0x14]
add dword [esp + 0x78], eax
mov eax, dword [esp + 0x30]
mov ecx, dword [eax + 0x10]
sub ecx, dword [eax + 0xc]
inc dword [esp + 0x1c]
sar ecx, 2
mov dword [esp + 0xc], edi
cmp dword [esp + 0x1c], ecx
jb 0x4763c5
mov esi, dword [esp + 0x20]
mov ecx, dword [esp + 0xc]
push 0x40824
lea eax, [esp + 0x7c]
push eax
mov eax, dword [esp + 0x18]
push 0xffffffffffffffff
lea eax, [eax + ecx*2]
push eax
push dword [ebp + 8]
call ebx
push dword [esp + 0x3c]
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SetTextColor]
cmp dword [esp + 0x28], 0
je 0x476560
push dword [esp + 0x28]
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SelectObject]
mov edi, dword [ebp + 0x10]
mov ebx, dword [ebp + 0xc]
neg edi
push edi
neg ebx
push ebx
add esi, 0xd8
push esi
mov esi, dword [sym.imp.USER32.dll_OffsetRect]
call esi
push edi
push ebx
push dword [esp + 0x48]
call esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc