Function at 0x408710
Capabilities:
Check if process is running under wine
Get common file path
Get number of processors
Get process heap flags
Hide graphical window
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
push eax
mov eax, 0x1488
call fcn.0040b6b8
sub esp, eax
mov eax, dword [esp + eax]
mov dword [ebp - 0x143c], edx
mov dword [ebp - 0x1448], eax
mov eax, dword [0x41402c]
mov dword [ebp - 0x1440], eax
test eax, eax
je 0x408750
mov eax, 1
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
lea eax, [ebp - 0xe24]
mov dword [esp + 0xc], 1
mov dword [esp + 0x10], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.SoftwareWineWineFile
mov dword [esp], 0x80000001
call sym._RegOpenKeyExW_20
lea eax, [ebp - 0x1224]
mov dword [ebp - 0x1224], 4
sub esp, 0x14
mov dword [esp + 0x14], eax
lea eax, [ebp - 0xc1c]
mov dword [ebp - 0x1444], eax
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1024]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.startX
mov eax, dword [ebp - 0xe24]
mov dword [esp], eax
call sym._RegQueryValueExW_24
sub esp, 0x18
test eax, eax
je 0x4087de
mov dword [ebp - 0xc1c], 0x80000000
mov dword [ebp - 0x1224], 4
lea eax, [ebp - 0x1224]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0xc18]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1024]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.startY
mov eax, dword [ebp - 0xe24]
mov dword [esp], eax
call sym._RegQueryValueExW_24
sub esp, 0x18
test eax, eax
je 0x408835
mov dword [ebp - 0xc18], 0x80000000
mov dword [ebp - 0x1224], 4
lea eax, [ebp - 0x1224]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0xc14]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1024]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.width
mov eax, dword [ebp - 0xe24]
mov dword [esp], eax
call sym._RegQueryValueExW_24
sub esp, 0x18
test eax, eax
je 0x40888c
mov dword [ebp - 0xc14], 0x80000000
mov dword [ebp - 0x1224], 4
lea eax, [ebp - 0x1224]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0xc10]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1024]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.height
mov eax, dword [ebp - 0xe24]
mov dword [esp], eax
call sym._RegQueryValueExW_24
sub esp, 0x18
test eax, eax
je 0x4088e3
mov dword [ebp - 0xc10], 0x80000000
lea eax, [ebp - 0x1224]
lea esi, [ebp - 0x818]
mov dword [ebp - 0x1224], 0x5c
mov dword [esp + 0x14], eax
lea eax, [ebp - 0x1024]
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.logfont
mov eax, dword [ebp - 0xe24]
mov dword [esp], eax
call sym._RegQueryValueExW_24
sub esp, 0x18
test eax, eax
jne 0x408f80
mov eax, dword [ebp - 0xe24]
mov dword [esp], eax
call sym._RegCloseKey_4
sub esp, 4
mov dword [esp], esi
call sym._CreateFontIndirectW_4
mov edx, dword [ebp - 0xc14]
mov ecx, dword [ebp - 0xc10]
mov edi, dword [ebp - 0xc18]
mov dword [0x414054], eax
sub esp, 4
mov eax, dword [ebp - 0xc1c]
mov dword [ebp - 0x1458], edx
mov dword [ebp - 0x1454], ecx
mov dword [ebp - 0x1450], eax
mov dword [ebp - 0x144c], edi
mov dword [esp + 4], 0x66
mov eax, dword [0x414020]
mov dword [esp], eax
call sym._LoadMenuW_8
sub esp, 8
mov ebx, eax
mov dword [esp], eax
call sym._GetMenuItemCount_4
sub esp, 4
sub eax, 2
mov dword [esp], ebx
mov dword [esp + 4], eax
call sym._GetSubMenu_8
mov dword [0x414030], ebx
sub esp, 8
mov edi, eax
mov dword [esp], ebx
mov dword [esp + 4], 2
call sym._GetSubMenu_8
sub esp, 8
mov dword [0x41403c], eax
mov dword [esp], ebx
mov dword [esp + 4], 3
call sym._GetSubMenu_8
mov ebx, dword [0x414020]
mov dword [ebp - 0x1434], edi
sub esp, 8
mov edi, dword [0x414030]
mov dword [0x414040], eax
mov dword [ebp - 0x1430], 0xc000
mov dword [esp + 8], esi
mov dword [esp + 0xc], 0x400
mov dword [esp + 4], 0x4b0
mov dword [esp], ebx
call sym._LoadStringW_16
sub esp, 0x10
mov dword [esp + 0x2c], 0
mov dword [esp + 0x28], ebx
mov dword [esp + 0x24], edi
mov dword [esp + 0x20], 0
mov ecx, dword [ebp - 0x1454]
mov dword [esp + 0x1c], ecx
mov edx, dword [ebp - 0x1458]
mov dword [esp + 0x18], edx
mov edi, dword [ebp - 0x144c]
mov dword [esp + 0x14], edi
mov eax, dword [ebp - 0x1450]
mov dword [esp + 8], esi
mov esi, section..data
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0xcf0000
movzx eax, word [0x414028]
mov dword [esp], 0
mov dword [esp + 4], eax
call sym._CreateWindowExW_48
lea edx, [ebp - 0x1434]
sub esp, 0x30
mov dword [0x41402c], eax
mov dword [esp + 0x2c], edx
mov edx, dword [0x414020]
mov dword [esp + 0x24], 0
mov dword [esp + 0x28], edx
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0x52b00000
mov dword [esp + 8], 0
mov dword [esp + 4], str.MDICLIENT
mov dword [esp], 0
call sym._CreateWindowExW_48
sub esp, 0x30
mov dword [0x414044], eax
mov dword [esp + 8], 8
mov dword [esp + 4], 0x1fb
mov eax, dword [0x414040]
mov dword [esp], eax
call sym._CheckMenuItem_12
sub esp, 0xc
mov dword [esp + 8], 0
mov dword [esp + 4], 0x1ff
mov eax, dword [0x414040]
mov dword [esp], eax
call sym._CheckMenuItem_12
sub esp, 0xc
call dbg.create_drive_bar
lea eax, [ebp - 0xc1c]
mov edi, dword [ebp - 0x1444]
mov ecx, 0x19
rep movsd dword es:[edi], dword [esi]
mov dword [esp + 0x30], 0x14
mov dword [esp + 0x2c], 0xf
mov dword [esp + 0x28], 0x10
mov dword [esp + 0x24], 0xf
mov dword [esp + 0x20], 0x10
mov dword [esp + 0x1c], 5
mov dword [ebp - 0x1444], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], 0x64
mov eax, dword [0x414020]
mov dword [esp + 0xc], 2
mov dword [esp + 0x10], eax
mov dword [esp + 8], 0x101
mov dword [esp + 4], 0x50000000
mov eax, dword [0x41402c]
mov dword [esp], eax
call sym._CreateToolbarEx_52
sub esp, 0x34
mov dword [0x41404c], eax
mov dword [esp + 8], 8
mov dword [esp + 4], 0x1fc
mov eax, dword [0x414040]
mov dword [esp], eax
call sym._CheckMenuItem_12
sub esp, 0xc
mov dword [esp + 0xc], 0x100
mov eax, dword [0x41402c]
mov dword [esp + 4], 0
mov dword [esp + 8], eax
mov dword [esp], 0x50000000
call sym._CreateStatusWindowW_16
sub esp, 0x10
mov dword [0x414048], eax
mov dword [esp + 8], 8
mov dword [esp + 4], 0x1f7
mov eax, dword [0x414040]
mov dword [esp], eax
call sym._CheckMenuItem_12
mov eax, dword [ebp - 0x143c]
sub esp, 0xc
test eax, eax
je 0x408f50
cmp word [eax], 0
je 0x408f50
mov eax, dword [ebp - 0x1448]
mov dword [esp + 4], eax
mov eax, dword [0x41402c]
mov dword [esp], eax
call sym._ShowWindow_8
mov eax, dword [0x414870]
lea ecx, [ebp - 0x1024]
mov ebx, dword [0x41402c]
sub esp, 8
mov edx, dword [eax]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], ecx
mov esi, dword [ebp - 0x1444]
mov dword [esp + 0x10], esi
mov edi, dword [ebp - 0x143c]
mov dword [esp + 8], 0
mov dword [esp + 0xc], edi
mov dword [esp + 4], ebx
mov dword [esp], eax
call dword [edx + 0xc]
sub esp, 0x1c
test eax, eax
js 0x408cd2
mov eax, dword [ebp - 0x1024]
mov dword [ebp - 0x1440], eax
mov edx, dword [ebp - 0x1440]
mov eax, dword [ebp - 0x143c]
mov ecx, ebx
call dbg.alloc_child_window
mov dword [eax + 0x138], 3
mov ebx, eax
mov dword [eax + 0x14c], 0
mov dword [eax + 0x150], 0
mov dword [eax + 0x154], 0x140
mov dword [eax + 0x158], 0x118
call dbg.create_child_window
test eax, eax
je 0x408fb0
lea eax, [ebx + 0x130]
mov dword [esp + 4], eax
mov eax, dword [ebx]
mov dword [esp], eax
call sym._SetWindowPlacement_8
sub esp, 8
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0xff00
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0x10
mov dword [esp + 4], 0x66
mov eax, dword [0x414020]
mov dword [esp], eax
call sym._ImageList_LoadImageW_28
mov dword [0x414868], 0
mov dword [0x414064], eax
mov eax, dword [0x41402c]
sub esp, 0x1c
mov dword [esp], eax
call sym._UpdateWindow_4
mov eax, dword [ebx]
sub esp, 4
test eax, eax
je 0x408741
mov eax, dword [ebp - 0x143c]
cmp word [eax], 0
je 0x408741
xor eax, eax
mov ecx, pe_nt_image_headers32
lea edi, [ebp - 0x1224]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x1024]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1224]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x1424]
mov dword [esp + 8], eax
lea eax, [ebp - 0x142c]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x143c]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll__wsplitpath]
cmp word [ebp - 0x1224], 0
je 0x408741
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0x18b
mov eax, dword [ebx + 0x98]
mov dword [esp], eax
call sym._SendMessageW_16
mov esi, dword [ebp - 0x1444]
mov edx, eax
sub esp, 0x10
xor eax, eax
lea esi, [esi]
movzx ecx, word [ebp + eax - 0x1224]
mov word [esi + eax], cx
add eax, 2
test cx, cx
jne 0x408e40
cmp word [ebp - 0xc1c], 0
mov ecx, dword [ebp - 0x1444]
je 0x408e71
lea esi, [esi]
add ecx, 2
cmp word [ecx], 0
jne 0x408e68
xor eax, eax
lea esi, [esi]
nop
movzx esi, word [ebp + eax - 0x1024]
mov word [ecx + eax], si
add eax, 2
test si, si
jne 0x408e78
test edx, edx
jle 0x408741
mov dword [ebp - 0x143c], edx
xor edi, edi
jmp 0x408ecf
mov eax, dword [ebp - 0x1444]
lea edx, [esi + 0x24c]
mov dword [esp], edx
mov dword [esp + 4], eax
call dword [sym.imp.kernel32.dll_lstrcmpW]
sub esp, 8
test eax, eax
je 0x408f13
add edi, 1
cmp dword [ebp - 0x143c], edi
je 0x408741
mov dword [esp + 0xc], 0
mov dword [esp + 8], edi
mov dword [esp + 4], 0x199
mov eax, dword [ebx + 0x98]
mov dword [esp], eax
call sym._SendMessageW_16
mov esi, eax
mov eax, dword [ebp - 0x1444]
sub esp, 0x10
mov dword [esp + 4], eax
lea eax, [esi + 0x44]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_lstrcmpW]
sub esp, 8
test eax, eax
jne 0x408ea0
mov dword [esp + 0xc], 0
mov dword [esp + 8], edi
mov dword [esp + 4], 0x186
mov eax, dword [ebx + 0x98]
mov dword [esp], eax
call sym._SendMessageW_16
mov eax, dword [ebx + 0x98]
sub esp, 0x10
mov dword [esp], eax
call sym._SetFocus_4
sub esp, 4
jmp 0x408741
lea eax, [ebp - 0xe24]
mov dword [esp], 0x104
mov dword [esp + 4], eax
call dword [sym.imp.kernel32.dll_GetCurrentDirectoryW]
lea eax, [ebp - 0xe24]
mov dword [ebp - 0x143c], eax
sub esp, 8
jmp 0x408c60
mov dword [esp], 0x11
call sym._GetStockObject_4
sub esp, 4
mov dword [esp + 8], esi
mov dword [esp + 4], 0x5c
mov dword [esp], eax
call sym._GetObjectW_12
sub esp, 0xc
jmp 0x408934
mov dword [esp + 8], ebx
mov dword [esp + 4], 0
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_HeapFree]
xor eax, eax
sub esp, 0xc
jmp 0x408746