Function at 0x51b190
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x58f7a0
mov eax, dword fs:[0]
push eax
sub esp, 0x6c
mov eax, dword [0x5cca0c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov eax, dword [esi + 0x38]
mov eax, dword [eax]
mov dword [ebp - 0x5c], esi
add esi, 0x34
mov ebx, esi
mov edi, eax
mov dword [ebp - 0x50], ebx
mov dword [ebp - 0x4c], edi
test ebx, ebx
mov eax, dword [esi + 4]
mov dword [ebp - 0x54], eax
je 0x51b1e0
cmp ebx, esi
je 0x51b1e5
call fcn.005532de
cmp edi, dword [ebp - 0x54]
je 0x51b382
test ebx, ebx
jne 0x51b1f7
call fcn.005532de
cmp edi, dword [ebx + 4]
jne 0x51b201
call fcn.005532de
mov ecx, dword [ebp + 0xc]
cmp dword [edi + 0x10], ecx
je 0x51b219
lea ecx, [ebp - 0x50]
call fcn.00517c40
mov ebx, dword [ebp - 0x50]
mov edi, dword [ebp - 0x4c]
jmp 0x51b1d2
lea esi, [ebp - 0x78]
mov dword [ebp - 0x54], 0
call fcn.00519280
cmp dword [eax + 0x18], 0x10
jb 0x51b233
mov edi, dword [eax + 4]
jmp 0x51b236
lea edi, [eax + 4]
test edi, edi
jne 0x51b23e
xor esi, esi
jmp 0x51b286
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ebx, eax
add ebx, 1
cmp ebx, 0x3fffffff
jg 0x51b27f
lea eax, [ebx + ebx]
call fcn.00553150
mov esi, esp
test esi, esi
je 0x51b27f
push ebx
push esi
push 0xffffffffffffffff
push edi
push 0
push 0x3a8
mov word [esi], 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
neg eax
sbb eax, eax
and eax, esi
jmp 0x51b281
xor eax, eax
mov ebx, dword [ebp - 0x50]
mov esi, eax
cmp dword [ebp - 0x60], 0x10
jb 0x51b298
mov ecx, dword [ebp - 0x74]
push ecx
call fcn.0055215c
add esp, 4
mov edi, dword [ebp - 0x4c]
cmp edi, dword [ebx + 4]
mov dword [ebp - 0x60], 0xf
mov dword [ebp - 0x64], 0
mov byte [ebp - 0x74], 0
jne 0x51b2b7
call fcn.005532de
push 0x30
add edi, 0x14
push edi
push 0
push esi
lea edx, [ebp - 0x48]
push edx
lea ecx, [ebp - 0x54]
call fcn.00417960
cmp dword [ebp - 0x30], 0x10
mov ebx, dword [ebp - 0x44]
mov dword [ebp - 4], 0
jae 0x51b2df
lea ebx, [ebp - 0x44]
lea eax, [ebp - 0x2c]
push eax
call fcn.00518b90
add esp, 4
mov eax, dword [ebp - 0x28]
mov esi, 8
cmp dword [ebp - 0x14], esi
mov byte [ebp - 4], 1
jae 0x51b2ff
lea eax, [ebp - 0x28]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x51b34e
cmp dword [ebp - 0x14], esi
mov esi, dword [ebp - 0x28]
jae 0x51b315
lea esi, [ebp - 0x28]
mov edi, dword [ebp - 0x4c]
mov ecx, dword [ebp - 0x50]
cmp edi, dword [ecx + 4]
jne 0x51b325
call fcn.005532de
mov edx, dword [ebp - 0x5c]
mov edi, dword [edi + 0xc]
mov ebx, dword [edx + 4]
call fcn.004a1350
test eax, eax
je 0x51b34e
push str.uiview_set_bitmap_path_by_index
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x51b34e
push esi
push 1
push edi
push ebx
call eax
cmp dword [ebp - 0x14], 8
jb 0x51b360
mov eax, dword [ebp - 0x28]
push eax
call fcn.0055215c
add esp, 4
xor eax, eax
cmp dword [ebp - 0x30], 0x10
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], eax
mov word [ebp - 0x28], ax
jb 0x51b382
mov ecx, dword [ebp - 0x44]
push ecx
call fcn.0055215c
add esp, 4
xor eax, eax
lea esp, [ebp - 0x88]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00552d63
mov esp, ebp
pop ebp
ret 0x10