100 ItemInfo.
cbSize =
sizeof(ItemInfo);
139 if (
buf[0] == 0xD0 &&
buf[1] == 0xCF &&
buf[2] == 0x11 &&
buf[3] == 0xE0 &&
140 buf[4] == 0xA1 &&
buf[5] == 0xB1 &&
buf[6] == 0x1A &&
buf[7] == 0xE1)
144 if (
buf[0] ==
'M' ||
buf[0] ==
'Z')
150 if (
buf[0] ==
'M' &&
buf[1] ==
'S' &&
buf[2] ==
'C' &&
buf[3] ==
'F')
242 static BOOL CachedDirectoryInitialized =
FALSE;
244 if (!CachedDirectoryInitialized)
258 CachedDirectory.
Empty();
263 CachedDirectory.
Empty();
266 CachedDirectoryInitialized =
TRUE;
282 DWORD dwCategoryNum = 1;
288 L"SYSTEM\\CurrentControlSet\\Services\\EventLog\\Application\\ReactOS Application Manager",
REG_NONE,
350 if (szVersionResult !=
NULL)
412 pDevMode.
dmSize =
sizeof(pDevMode);
466 NameInfo Name1,
Name2;
518 Value.ReleaseBuffer();
519 return Value.GetString();
533 buf.ReleaseBuffer(
cch - 1);
575 int sep =
dir.FindFileName();
578 *pDir = sep == -1 ?
L"" :
dir.m_strPath.Left(sep - 1);
587 Path.ReleaseBuffer();
648 if (
buf[0] == 0xD0 &&
buf[1] == 0xCF &&
buf[2] == 0x11 &&
buf[3] == 0xE0)
657 if (
buf[0] !=
'M' ||
buf[1] !=
'Z')
665 if (sig[0] == 0x6F6E6E49 && sig[1] == ~sig[2])
675 UINT nsis[1+1+3+1+1], nsisskip = 512;
676 for (
UINT nsisoffset = nsisskip * 20; nsisoffset < 1024 * 1024 * 50; nsisoffset += nsisskip)
678 if (
ReadAt(
hFile, nsisoffset, nsis,
sizeof(nsis)) && nsis[1] == 0xDEADBEEF)
680 if (nsis[2] == 0x6C6C754E && nsis[3] == 0x74666F73 && nsis[4] == 0x74736E49)
692 enum { INNORCSETUPLDR = 11111 };
699 if (
p[0] ==
'r' &&
p[1] ==
'D' &&
p[2] ==
'l' &&
p[3] ==
'P' &&
p[4] ==
't' &&
p[5] ==
'S')
724 LPCWSTR pszInnoParams =
L"/SILENT /VERYSILENT /SP-";
728 Parameters.Format(
L"%s /SUPPRESSMSGBOXES", pszInnoParams);
PRTL_UNICODE_STRING_BUFFER Path
static CStringW BuildPath(const T &Base, LPCWSTR Append)
SETTINGS_INFO SettingsInfo
BOOL WriteLogMessage(WORD wType, DWORD dwEventID, LPCWSTR lpMsg)
bool ExpandEnvStrings(CStringW &Str)
BOOL StartProcess(const CStringW &Path, BOOL Wait)
static BOOL IsSameRegKey(HKEY hKey1, HKEY hKey2)
BOOL GetInstalledVersion(CStringW *pszVersion, const CStringW &szRegName)
BOOL OpensWithExplorer(PCWSTR Path)
VOID EmulateDialogReposition(HWND hwnd)
HRESULT GetProgramFilesPath(CStringW &Path, BOOL PerUser, HWND hwnd)
BOOL GetSilentInstallParameters(InstallerType InstallerType, UINT ExtraInfo, LPCWSTR Installer, CStringW &Parameters)
VOID ShowPopupMenuEx(HWND hwnd, HWND hwndOwner, UINT MenuID, UINT DefaultItem, POINT *Point)
UINT ClassifyFile(PCWSTR Path)
HRESULT GetKnownPath(REFKNOWNFOLDERID kfid, CStringW &Path, DWORD Flags)
UINT CreateDirectoryTree(LPCWSTR Dir)
BOOL GetStorageDirectory(CStringW &Directory)
EXTERN_C NTSTATUS WINAPI NtQueryObject(HANDLE, OBJECT_INFORMATION_CLASS, PVOID, ULONG, PULONG)
BOOL GetInstalledVersion_WowUser(CStringW *szVersionResult, const CStringW &szRegName, BOOL IsUserKey, REGSAM keyWow)
InstallerType GuessInstallerType(LPCWSTR Installer, UINT &ExtraInfo)
INT GetSystemColorDepth()
VOID CopyTextToClipboard(LPCWSTR lpszText)
BOOL DeleteDirectoryTree(LPCWSTR Dir, HWND hwnd)
BOOL SearchPatternMatch(LPCWSTR szHaystack, LPCWSTR szNeedle)
LPCWSTR GetRegString(CRegKey &Key, LPCWSTR Name, CStringW &Value)
HRESULT GetSpecialPath(UINT csidl, CStringW &Path, HWND hwnd)
CStringW SplitFileAndDirectory(LPCWSTR FullPath, CStringW *pDir)
BOOL IsZipFile(PCWSTR Path)
UINT ErrorBox(HWND hOwner, UINT Error)
static INT_PTR CALLBACK NothingDlgProc(HWND hDlg, UINT uMsg, WPARAM, LPARAM)
static BOOL ReadAt(HANDLE Handle, UINT Offset, LPVOID Buffer, UINT Size)
void UnixTimeToFileTime(DWORD dwUnixTime, LPFILETIME pFileTime)
HRESULT RegKeyHasValues(HKEY hKey, LPCWSTR Path, REGSAM wowsam)
LONG Open(HKEY hKeyParent, LPCTSTR lpszKeyName, REGSAM samDesired=KEY_READ|KEY_WRITE) noexcept
bool IsEmpty() const noexcept
void ReleaseBuffer(_In_ int nNewLength=-1)
#define NT_SUCCESS(StatCode)
NTSTATUS NTAPI RtlGetVersion(IN OUT PRTL_OSVERSIONINFOW lpVersionInformation)
LONG WINAPI RegEnumValueW(_In_ HKEY hKey, _In_ DWORD index, _Out_ LPWSTR value, _Inout_ PDWORD val_count, _Reserved_ PDWORD reserved, _Out_opt_ PDWORD type, _Out_opt_ LPBYTE data, _Inout_opt_ PDWORD count)
BOOL WINAPI ReportEventW(IN HANDLE hEventLog, IN WORD wType, IN WORD wCategory, IN DWORD dwEventID, IN PSID lpUserSid, IN WORD wNumStrings, IN DWORD dwDataSize, IN LPCWSTR *lpStrings, IN LPVOID lpRawData)
BOOL WINAPI DeregisterEventSource(IN HANDLE hEventLog)
HANDLE WINAPI RegisterEventSourceW(IN LPCWSTR lpUNCServerName, IN LPCWSTR lpSourceName)
LPWSTR WINAPI StrStrIW(LPCWSTR lpszStr, LPCWSTR lpszSearch)
#define ReadFile(a, b, c, d, e)
#define GetProcAddress(x, y)
#define INVALID_HANDLE_VALUE
#define ERROR_NO_MORE_ITEMS
DWORD WINAPI ExpandEnvironmentStringsW(IN LPCWSTR lpSrc, IN LPWSTR lpDst, IN DWORD nSize)
BOOL WINAPI CreateDirectoryW(IN LPCWSTR lpPathName, IN LPSECURITY_ATTRIBUTES lpSecurityAttributes)
DWORD WINAPI GetModuleFileNameW(HINSTANCE hModule, LPWSTR lpFilename, DWORD nSize)
BOOL WINAPI DECLSPEC_HOTPATCH CreateProcessW(LPCWSTR lpApplicationName, LPWSTR lpCommandLine, LPSECURITY_ATTRIBUTES lpProcessAttributes, LPSECURITY_ATTRIBUTES lpThreadAttributes, BOOL bInheritHandles, DWORD dwCreationFlags, LPVOID lpEnvironment, LPCWSTR lpCurrentDirectory, LPSTARTUPINFOW lpStartupInfo, LPPROCESS_INFORMATION lpProcessInformation)
HRSRC WINAPI FindResourceW(HINSTANCE hModule, LPCWSTR name, LPCWSTR type)
LPVOID WINAPI LockResource(HGLOBAL handle)
HGLOBAL WINAPI LoadResource(HINSTANCE hModule, HRSRC hRsrc)
WCHAR *WINAPI PathFindFileNameW(const WCHAR *path)
LPWSTR WINAPI PathFindExtensionW(const WCHAR *path)
int WINAPI StrCmpIW(const WCHAR *str, const WCHAR *comp)
DWORD WINAPI GetVersion(void)
_ACRTIMP size_t __cdecl wcslen(const wchar_t *)
BOOL WINAPI SHGetSpecialFolderPathW(HWND hwndOwner, LPWSTR szPath, int nFolder, BOOL bCreate)
HRESULT WINAPI AssocQueryStringW(ASSOCF cfFlags, ASSOCSTR str, LPCWSTR pszAssoc, LPCWSTR pszExtra, LPWSTR pszOut, DWORD *pcchOut)
BOOL WINAPI IsOS(DWORD feature)
void WINAPI PathRemoveArgsW(LPWSTR lpszPath)
ULONG RtlCompareUnicodeString(PUNICODE_STRING s1, PUNICODE_STRING s2, BOOLEAN UpCase)
_Must_inspect_result_ _In_ PCUNICODE_STRING Name2
GLdouble GLdouble GLdouble r
GLenum GLuint GLenum GLsizei const GLchar * buf
GLuint64EXT GLuint GLuint GLenum GLenum GLuint GLuint GLenum GLuint GLuint key1
BOOL NTAPI GlobalUnlock(HGLOBAL hMem)
HGLOBAL NTAPI GlobalAlloc(UINT uFlags, SIZE_T dwBytes)
static ERESOURCE GlobalLock
void WINAPI CoTaskMemFree(void *ptr)
#define ERROR_ALREADY_EXISTS
PSDBQUERYRESULT_VISTA PVOID DWORD * dwSize
static PROCESS_INFORMATION pi
static HANDLE PIO_APC_ROUTINE PVOID PIO_STATUS_BLOCK io
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
#define REG_OPTION_NON_VOLATILE
#define FILE_SHARE_DELETE
#define Int32x32To64(a, b)
_In_ ULONG _In_ ULONG Offset
_In_ ULONG _In_ ULONG _In_ ULONG Length
static HANDLE ULONG_PTR dwData
#define MAKEINTRESOURCE(i)
@ ASSOCF_INIT_IGNOREUNKNOWN
enum _OBJECT_INFORMATION_CLASS OBJECT_INFORMATION_CLASS
DWORD_PTR WINAPI SHGetFileInfoW(LPCWSTR path, DWORD dwFileAttributes, SHFILEINFOW *psfi, UINT sizeofpsfi, UINT flags)
#define FOF_NOCONFIRMATION
int WINAPI SHFileOperationW(LPSHFILEOPSTRUCTW lpFileOp)
int WINAPI SHCreateDirectory(HWND hWnd, LPCWSTR path)
#define CSIDL_PROGRAM_FILES
#define CSIDL_LOCAL_APPDATA
@ PERCEIVED_TYPE_COMPRESSED
@ PERCEIVED_TYPE_APPLICATION
KNOWNFOLDERID * REFKNOWNFOLDERID
STRSAFEAPI StringCchCopyW(STRSAFE_LPWSTR pszDest, size_t cchDest, STRSAFE_LPCWSTR pszSrc)
base for all directory entries
ULONG dwOSVersionInfoSize
TW_UINT32 TW_UINT16 TW_UINT16 MSG
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_DEVICE_PROPERTY_DATA _In_ DEVPROPTYPE _In_ ULONG Size
_In_ WDFDMATRANSACTION _In_ size_t MaximumLength
_In_ WDFDPC _In_ BOOLEAN Wait
_Must_inspect_result_ _In_ WDFQUEUE _In_opt_ WDFREQUEST _In_opt_ WDFFILEOBJECT _Inout_opt_ PWDF_REQUEST_PARAMETERS Parameters
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING _Out_opt_ PUSHORT _Inout_opt_ PUNICODE_STRING Value
BOOL WINAPI EnumDisplaySettingsW(LPCWSTR lpszDeviceName, DWORD iModeNum, LPDEVMODEW lpDevMode)
DWORD WINAPI GetLastError(void)
#define STARTF_USESHOWWINDOW
#define LOAD_LIBRARY_AS_DATAFILE
#define FORMAT_MESSAGE_IGNORE_INSERTS
#define FORMAT_MESSAGE_FROM_SYSTEM
#define UnlockResource(handle)
static HRESULT HRESULT_FROM_WIN32(unsigned int x)
#define ERROR_OLD_WIN_VERSION
#define ERROR_INTERNAL_ERROR
#define EVENTLOG_ERROR_TYPE
#define EVENTLOG_INFORMATION_TYPE
#define EVENTLOG_WARNING_TYPE
#define HKEY_LOCAL_MACHINE
#define HKEY_CURRENT_USER
BOOL WINAPI TranslateMessage(_In_ const MSG *)
BOOL WINAPI SetMenuDefaultItem(_In_ HMENU, _In_ UINT, _In_ UINT)
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
BOOL WINAPI SetWindowPos(_In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
HANDLE WINAPI SetClipboardData(_In_ UINT, _In_opt_ HANDLE)
BOOL WINAPI SetForegroundWindow(_In_ HWND)
BOOL WINAPI CloseClipboard(void)
BOOL WINAPI GetCursorPos(_Out_ LPPOINT)
BOOL WINAPI OpenClipboard(_In_opt_ HWND)
DWORD WINAPI MsgWaitForMultipleObjects(_In_ DWORD nCount, _In_reads_opt_(nCount) CONST HANDLE *pHandles, _In_ BOOL fWaitAll, _In_ DWORD dwMilliseconds, _In_ DWORD dwWakeMask)
int WINAPI MessageBoxW(_In_opt_ HWND hWnd, _In_opt_ LPCWSTR lpText, _In_opt_ LPCWSTR lpCaption, _In_ UINT uType)
#define ENUM_CURRENT_SETTINGS
HMENU WINAPI GetSubMenu(_In_ HMENU, _In_ int)
HWND WINAPI SetFocus(_In_opt_ HWND)
BOOL WINAPI PeekMessageW(_Out_ LPMSG, _In_opt_ HWND, _In_ UINT, _In_ UINT, _In_ UINT)
BOOL WINAPI EmptyClipboard(void)
#define CreateDialogIndirectW(h, t, w, f)
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
BOOL WINAPI DestroyMenu(_In_ HMENU)
BOOL WINAPI GetMenuItemInfoW(_In_ HMENU, _In_ UINT, _In_ BOOL, _Inout_ LPMENUITEMINFOW)
LRESULT WINAPI DispatchMessageW(_In_ const MSG *)
BOOL WINAPI TrackPopupMenu(_In_ HMENU, _In_ UINT, _In_ int, _In_ int, _Reserved_ int, _In_ HWND, _Reserved_ LPCRECT)
#define MAKEINTRESOURCEW(i)
HMENU WINAPI LoadMenuW(_In_opt_ HINSTANCE, _In_ LPCWSTR)
BOOL WINAPI DestroyWindow(_In_ HWND)
HMENU WINAPI GetMenu(_In_ HWND)
_Must_inspect_result_ _In_ ULONG Flags