135 HRSRC GplTextResource;
146 if (
NULL == GplTextResource)
161 if (
NULL == GplTextMem)
167 if (
NULL == GplTextLocked)
173 GplText[
Size] =
'\0';
237 (
WPARAM)pSetupData->hTitleFont,
301 PWCHAR End, CurrentProject;
302 INT ProjectsSize, ProjectsCount;
319 if (
NULL == Projects)
324 if (0 == ProjectsCount)
329 if (ProjectsCount < ProjectsSize - 1)
337 CurrentProject = Projects;
338 while (*CurrentProject !=
L'\0')
340 End =
wcschr(CurrentProject,
L'\n');
348 CurrentProject = End + 1;
352 CurrentProject +=
wcslen(CurrentProject);
419 {
L"Terminal Server\0",
L"ServerNT", 0, 0x200, 0 },
420 {
L"\0",
L"WinNT", 1, 0x300, 1 },
421 {
L"Terminal Server\0",
L"ServerNT", 0, 0x200, 0 }
435 {
L".Default",
L"%SystemRoot%\\Media\\ReactOS_Default.wav" },
436 {
L"AppGPFault",
L"" },
438 {
L"CriticalBatteryAlarm",
L"%SystemRoot%\\Media\\ReactOS_Battery_Critical.wav" },
439 {
L"DeviceConnect",
L"%SystemRoot%\\Media\\ReactOS_Hardware_Insert.wav" },
440 {
L"DeviceDisconnect",
L"%SystemRoot%\\Media\\ReactOS_Hardware_Remove.wav" },
441 {
L"DeviceFail",
L"%SystemRoot%\\Media\\ReactOS_Hardware_Fail.wav" },
442 {
L"LowBatteryAlarm",
L"%SystemRoot%\\Media\\ReactOS_Battery_Low.wav" },
443 {
L"MailBeep",
L"%SystemRoot%\\Media\\ReactOS_Notify.wav" },
444 {
L"Maximize",
L"%SystemRoot%\\Media\\ReactOS_Restore.wav" },
445 {
L"MenuCommand",
L"%SystemRoot%\\Media\\ReactOS_Menu_Command.wav" },
446 {
L"MenuPopup",
L"" },
447 {
L"Minimize",
L"%SystemRoot%\\Media\\ReactOS_Minimize.wav" },
449 {
L"PrintComplete",
L"%SystemRoot%\\Media\\ReactOS_Print_Complete.wav" },
450 {
L"RestoreDown",
L"" },
451 {
L"RestoreUp",
L"" },
452 {
L"SystemAsterisk",
L"%SystemRoot%\\Media\\ReactOS_Ding.wav" },
453 {
L"SystemExclamation",
L"%SystemRoot%\\Media\\ReactOS_Exclamation.wav" },
454 {
L"SystemExit",
L"%SystemRoot%\\Media\\ReactOS_Shutdown.wav" },
455 {
L"SystemHand",
L"%SystemRoot%\\Media\\ReactOS_Critical_Stop.wav" },
456 {
L"SystemNotification",
L"%SystemRoot%\\Media\\ReactOS_Balloon.wav" },
457 {
L"SystemQuestion",
L"%SystemRoot%\\Media\\ReactOS_Ding.wav" },
458 {
L"SystemStart",
L"%SystemRoot%\\Media\\ReactOS_Startup.wav" },
459 {
L"WindowsLogoff",
L"%SystemRoot%\\Media\\ReactOS_LogOff.wav" }
465 {
L"EmptyRecycleBin",
L"%SystemRoot%\\Media\\ReactOS_Recycle.wav" },
466 {
L"Navigating",
L"%SystemRoot%\\Media\\ReactOS_Start.wav" }
475 HKEY hRootKey, hEventKey, hDefaultKey;
486 DPRINT1(
"RegOpenKeyExW failed\n");
566 DPRINT1(
"RegOpenKeyExW failed\n");
571 pszData =
pData->ProductSuite;
576 DPRINT1(
"RegSetValueExW failed\n");
581 pszData =
pData->ProductType;
586 DPRINT1(
"RegSetValueExW failed\n");
596 DPRINT1(
"RegOpenKeyExW failed\n");
601 dwValue =
pData->ReportAsWorkstation;
606 DPRINT1(
"RegSetValueExW failed\n");
616 DPRINT1(
"RegOpenKeyExW failed\n");
621 dwValue =
pData->CSDVersion;
626 DPRINT1(
"RegSetValueExW failed\n");
636 DPRINT1(
"RegOpenKeyExW failed\n");
641 dwValue =
pData->LogonType;
646 DPRINT1(
"RegSetValueExW failed\n");
660 WCHAR szShell[] =
L"cmd.exe";
665 DPRINT1(
"RegSetValueExW failed\n");
674 DPRINT1(
"RegOpenKeyExW failed\n");
682 DPRINT1(
"RegSetValueExW failed\n");
730 WCHAR szText[64], szDefault[64];
838 WCHAR * OwnerOrganization)
844 L"Software\\Microsoft\\Windows NT\\CurrentVersion",
868 L"RegisteredOrganization",
871 (
LPBYTE)OwnerOrganization,
885 WCHAR OwnerOrganization[51];
887 WCHAR ErrorName[256];
949 wcscpy(ErrorName,
L"Setup cannot continue until you enter your name.");
959 OwnerOrganization[0] = 0;
991 WCHAR ErrorComputerName[256];
1006 wcscpy(ErrorComputerName,
L"Setup failed to set the computer name.");
1025 L"SYSTEM\\CurrentControlSet\\Services\\Tcpip\\Parameters",
1043 DPRINT1(
"RegSetValueEx(\"Hostname\") failed (%08lX)\n", lError);
1050 DPRINT1(
"RegCreateKeyExW for Tcpip\\Parameters failed (%08lX)\n", lError);
1061 WCHAR szAdministratorName[256];
1067 szAdministratorName,
1070 wcscpy(szAdministratorName,
L"Administrator");
1074 L"SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon",
1082 L"DefaultDomainName",
1089 DPRINT1(
"RegSetValueEx(\"DefaultDomainName\") failed!\n");
1096 (
LPBYTE)szAdministratorName,
1097 (
wcslen(szAdministratorName)+ 1) *
sizeof(
WCHAR));
1100 DPRINT1(
"RegSetValueEx(\"DefaultUserName\") failed!\n");
1113 static const WCHAR Chars[] =
L"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
1114 static const unsigned cChars =
sizeof(Chars) /
sizeof(
WCHAR) - 1;
1122 for (
i = 8;
i < 15;
i++)
1135 WCHAR Password1[128];
1136 WCHAR Password2[128];
1139 WCHAR EmptyComputerName[256], NotMatchPassword[256], WrongPassword[256];
1169 if (pSetupData->UnattendSetup)
1172 if (pSetupData->ComputerName[0] ==
L'*' && !pSetupData->ComputerName[1])
1173 wcscpy(pSetupData->ComputerName, ComputerName);
1209 wcscpy(EmptyComputerName,
L"Setup cannot continue until you enter the name of your computer.");
1227#ifdef PASSWORDS_MANDATORY
1235 wcscpy(EmptyPassword,
L"You must enter a password !");
1246 if (
wcscmp(Password1, Password2))
1251 wcscpy(NotMatchPassword,
L"The passwords you entered do not match. Please enter the desired password again.");
1267 wcscpy(WrongPassword,
L"The password you entered contains invalid characters. Please enter a cleaned password.");
1281 pSetupData->UnattendSetup =
FALSE;
1301 WCHAR CurLocale[256] =
L"";
1303 WCHAR ResText[256] =
L"";
1304 WCHAR LocaleText[256 * 2];
1323 WCHAR LayoutName[128];
1324 WCHAR LayoutPath[256];
1325 WCHAR ResText[256] =
L"";
1377 dwSize =
sizeof(szLayoutId);
1380 wcscpy(szKLID, szLayoutId);
1388 L"SYSTEM\\CurrentControlSet\\Control\\Keyboard Layouts\\%s",
1393 dwSize =
sizeof(LayoutName);
1402 wcscpy(LayoutName, szKLID);
1420 if (!pwszCPLParameters)
1426 ZeroMemory(&StartupInfo,
sizeof(StartupInfo));
1427 StartupInfo.
cb =
sizeof(StartupInfo);
1428 ZeroMemory(&ProcessInformation,
sizeof(ProcessInformation));
1442 &ProcessInformation))
1496 else if (
_wcsicmp(pszExt,
L".msstyles") == 0)
1501 DPRINT1(
"EnableVisualTheme(): Unknown file '%S'\n", ThemeFile);
1506 DPRINT1(
"Applying visual %s '%S'\n",
1508 ThemeFile ? ThemeFile :
L"(Classic)");
1524 szStyleFile,
_countof(szStyleFile), ThemeFile) && *szStyleFile)
1527 ThemeFile = szStyleFile;
1536 DPRINT1(
"--> Applying visual style '%S'\n",
1537 ThemeFile ? ThemeFile :
L"(Classic)");
1542 WCHAR wszParams[1024];
1544 PCWSTR format =
L"desk.cpl,,2 /Action:ActivateMSTheme /file:\"%s\"";
1561 WCHAR Locale[9] =
L"0000";
1688 ULONG DescriptionSize;
1689 ULONG StandardNameSize;
1690 ULONG DaylightNameSize;
1698 DescriptionSize =
sizeof(
Entry->Description);
1699 StandardNameSize =
sizeof(
Entry->StandardName);
1700 DaylightNameSize =
sizeof(
Entry->DaylightName);
1704 &
Entry->TimezoneInfo,
1707 Entry->StandardName,
1709 Entry->DaylightName,
1728 if (Current !=
NULL)
1742 Entry->Next = Current;
1793 return (
Entry->TimezoneInfo.StandardDate.wMonth != 0 &&
1794 Entry->TimezoneInfo.DaylightDate.wMonth != 0);
1804 if (
Entry->Index == dwEntryIndex)
1852 if (dwEntryIndex != 0 && dwEntryIndex ==
Entry->Index)
1890 Entry->StandardName);
1892 Entry->DaylightName);
1894 TimeZoneInformation.
Bias =
Entry->TimezoneInfo.Bias;
1899 &
Entry->TimezoneInfo.StandardDate,
1902 &
Entry->TimezoneInfo.DaylightDate,
1966 WCHAR ErrorLocalTime[256];
1983 wcscpy(ErrorLocalTime,
L"Setup was unable to set the local time.");
2037 dwEntryIndex = (
DWORD)-1;
2172 WCHAR DisplayName[100] = {0};
2184 lvi.pszText = DisplayName;
2206 int iTheme = pnmv->
iItem;
2207 DPRINT1(
"Selected theme: %u\n",
Themes[iTheme].DisplayName);
2209 if (
Themes[iTheme].ThemeFile)
2278 DPRINT(
"Received SPFILENOTIFY_STARTREGISTRATION notification for %S\n",
2287 DPRINT(
"Received SPFILENOTIFY_ENDREGISTRATION notification for %S\n",
2352 WCHAR SectionName[512];
2358 RegistrationData.
hwndDlg = pItemsData->hwndDlg;
2364 DPRINT1(
"No RegistrationPhase2 section found\n");
2372 DPRINT1(
"Unable to retrieve section name\n");
2377 DPRINT(
"SectionName %S DllCount %ld\n", SectionName, DllCount);
2385 RegistrationData.
pNotify = pNotify;
2391 L"RegistrationPhase2",
2406 DPRINT(
"Catching exception\n");
2421 WCHAR SectionName[512];
2433 DPRINT1(
"No RegistrationPhase2 section found\n");
2441 DPRINT1(
"Unable to retrieve section name\n");
2451 DPRINT(
"Register Components: %ld Steps\n", Steps);
2459 DPRINT(
"Register Components: done\n");
2478 DPRINT(
"Install security: %ld Steps\n", Steps);
2485 DPRINT(
"Install security: done\n");
2499 hwndDlg = pItemsData->
hwndDlg;
2534 HANDLE hCompletionThread;
2538 if (pItemsData ==
NULL)
2541 pItemsData->
hwndDlg = hwndDlg;
2549 if (hCompletionThread ==
NULL)
2569 WCHAR UnknownError[84];
2579 wcscpy(UnknownError,
L"Unknown error");
2582 _ultow(LastError, UnknownError +
wcslen(UnknownError), 10);
2652 static HICON s_hCheckIcon, s_hArrowIcon, s_hCrossIcon;
2653 static HFONT s_hNormalFont;
2732 DPRINT(
"PM_STEP_START\n");
2749 DPRINT(
"PM_ITEMS_DONE\n");
2767 DWORD InProgress = 0;
2909 WCHAR wszDrives[512];
2910 WCHAR wszNTPath[512];
2917 if (cchDrives == 0 || cchDrives >=
_countof(wszDrives))
2924 for (pwszDrive = wszDrives; *pwszDrive; pwszDrive +=
wcslen(pwszDrive) + 1)
2931 pwszDrive[2] =
L'\\';
2936 wsprintf(wszBuf,
L"Testing '%s' --> '%s' %s a CD",
2937 pwszDrive, wszNTPath,
2942 if (!
_wcsicmp(wszNTPath, pwszNTPath))
2945 wcscpy(pwszPath, pwszDrive);
2948 wsprintf(wszBuf,
L"GetInstallSourceWin32: %s", pwszPath);
2972 L"UnattendSetupEnabled",
2991 DPRINT(
"Unattend setup was disabled by UnattendSetupEnabled key.\n");
2995 pSetupData->UnattendSetup =
TRUE;
3030 if (
ARRAYSIZE(pSetupData->OwnerName) > LineLength)
3032 wcscpy(pSetupData->OwnerName, szValue);
3037 if (
ARRAYSIZE(pSetupData->OwnerOrganization) > LineLength)
3039 wcscpy(pSetupData->OwnerOrganization, szValue);
3044 if (
ARRAYSIZE(pSetupData->ComputerName) > LineLength)
3046 wcscpy(pSetupData->ComputerName, szValue);
3051 if (
ARRAYSIZE(pSetupData->AdminPassword) > LineLength)
3053 wcscpy(pSetupData->AdminPassword, szValue);
3058 pSetupData->TimeZoneIndex =
_wtoi(szValue);
3062 pSetupData->DisableAutoDaylightTimeSet =
_wtoi(szValue);
3067 pSetupData->RappsDownload =
TRUE;
3069 pSetupData->RappsDownload =
FALSE;
3108 iValue =
_wtoi(szValue);
3141 L"SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\RunOnce",
3146 DPRINT1(
"Error: failed to open HKLM\\Software\\Microsoft\\Windows\\CurrentVersion\\RunOnce\n");
3196 DPRINT1(
"Error: failed to open HKLM\\SYSTEM\\CurrentControlSet\\Control\\Session Manager\\Environment\n");
3258 return (
_wcsicmp(szPath1, szPath2) == 0);
3268 DWORD dwPathLength = 0;
3269 DWORD dwNewLength = 0;
3275 L"Installation Sources",
3283 dwPathLength == 0 ||
3284 dwPathLength %
sizeof(
WCHAR) != 0)
3291 dwNewLength = dwPathLength + (
wcslen(lpPath) + 1) *
sizeof(
WCHAR);
3300 L"Installation Sources",
3327 if (dwPathLength == 0)
3329 dwNewLength = (
wcslen(lpPath) + 1 + 1) *
sizeof(
WCHAR);
3342 L"Installation Sources",
3416 _swprintf(szValue,
L"\"%s\"", pSetupData->SourcePath);
3428 L"Software\\Microsoft\\Windows NT\\CurrentVersion",
3440 L"Software\\Microsoft\\Windows\\CurrentVersion\\Setup",
3455 (
LPBYTE)pSetupData->SourcePath,
3456 (
wcslen(pSetupData->SourcePath) + 1) *
sizeof(
WCHAR));
3459 L"ServicePackSourcePath",
3462 (
LPBYTE)pSetupData->SourcePath,
3463 (
wcslen(pSetupData->SourcePath) + 1) *
sizeof(
WCHAR));
3498 DWORD dwPageCount = 10, dwNetworkPageCount = 0;
3500 LogItem(
L"BEGIN_SECTION",
L"InstallWizard");
3506 if (pSetupData ==
NULL)
3510 L"Setup failed to allocate global data!",
3518 if (hNetShell !=
NULL)
3520 DPRINT(
"Netshell.dll loaded!\n");
3523 "NetSetupRequestWizardPages");
3526 pfn(&dwNetworkPageCount,
NULL,
NULL);
3527 dwPageCount += dwNetworkPageCount;
3531 DPRINT(
"PageCount: %lu\n", dwPageCount);
3540 L"Setup failed to allocate page array!",
3553 psp.lParam = (
LPARAM)pSetupData;
3559 psp.dwFlags =
PSP_DEFAULT | PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE;
3567 psp.dwFlags =
PSP_DEFAULT | PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE;
3575 psp.dwFlags =
PSP_DEFAULT | PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE;
3583 psp.dwFlags =
PSP_DEFAULT | PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE;
3591 psp.dwFlags =
PSP_DEFAULT | PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE;
3599 psp.dwFlags =
PSP_DEFAULT | PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE;
3607 psp.dwFlags =
PSP_DEFAULT | PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE;
3619 pfn(&dwNetworkPageCount, &phpage[nPages], pSetupData);
3620 nPages += dwNetworkPageCount;
3624 psp.dwFlags =
PSP_DEFAULT | PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE;
3637 ASSERT(nPages == dwPageCount);
3641 psh.dwFlags = PSH_WIZARD97 | PSH_WATERMARK | PSH_HEADER |
PSH_MODELESS;
3643 psh.hwndParent =
NULL;
3644 psh.nPages = nPages;
3646 psh.phpage = phpage;
3677 if (hNetShell !=
NULL)
3680 if (pSetupData !=
NULL)
3683 LogItem(
L"END_SECTION",
L"InstallWizard");
PRTL_UNICODE_STRING_BUFFER Path
static VOID ErrorMessage(_In_ DWORD dwErrorCode, _In_opt_ PCWSTR pszMsg,...)
#define ShowDlgItem(hDlg, nID, nCmdShow)
struct _SETUPDATA * PSETUPDATA
#define IDS_PROCESSSUBTITLE
#define IDC_PROCESSPROGRESS
#define IDC_RESTART_PROGRESS
#define RegCloseKey(hKey)
static HINSTANCE hDllInstance
BOOL WINAPI SetComputerNameW(LPCWSTR lpComputerName)
BOOL WINAPI SetComputerNameExW(COMPUTER_NAME_FORMAT NameType, LPCWSTR lpBuffer)
#define ERROR_NOT_ENOUGH_MEMORY
static CHAR Title[MAX_PATH]
BOOL WINAPI SHIM_OBJ_NAME() Notify(DWORD fdwReason, PVOID ptr)
#define IDS_REACTOS_SETUP
LONG WINAPI RegCreateKeyExW(_In_ HKEY hKey, _In_ LPCWSTR lpSubKey, _In_ DWORD Reserved, _In_opt_ LPWSTR lpClass, _In_ DWORD dwOptions, _In_ REGSAM samDesired, _In_opt_ LPSECURITY_ATTRIBUTES lpSecurityAttributes, _Out_ PHKEY phkResult, _Out_opt_ LPDWORD lpdwDisposition)
LONG WINAPI RegOpenKeyExW(HKEY hKey, LPCWSTR lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
LONG WINAPI RegSetValueExW(_In_ HKEY hKey, _In_ LPCWSTR lpValueName, _In_ DWORD Reserved, _In_ DWORD dwType, _In_ CONST BYTE *lpData, _In_ DWORD cbData)
LONG WINAPI RegQueryValueExW(_In_ HKEY hkeyorg, _In_ LPCWSTR name, _In_ LPDWORD reserved, _In_ LPDWORD type, _In_ LPBYTE data, _In_ LPDWORD count)
INT WINAPI ImageList_AddMasked(HIMAGELIST himl, HBITMAP hBitmap, COLORREF clrMask)
HIMAGELIST WINAPI ImageList_Create(INT cx, INT cy, UINT flags, INT cInitial, INT cGrow)
#define GetProcAddress(x, y)
#define INVALID_HANDLE_VALUE
#define HeapFree(x, y, z)
static void cleanup(void)
#define IDS_UNKNOWN_ERROR
DWORD WINAPI QueryDosDeviceW(LPCWSTR lpDeviceName, LPWSTR lpTargetPath, DWORD ucchMax)
DWORD WINAPI ExpandEnvironmentStringsW(IN LPCWSTR lpSrc, IN LPWSTR lpDst, IN DWORD nSize)
UINT WINAPI GetDriveTypeW(IN LPCWSTR lpRootPathName)
DWORD WINAPI GetLogicalDriveStringsW(IN DWORD nBufferLength, IN LPWSTR lpBuffer)
DWORD WINAPI GetFileAttributesW(LPCWSTR lpFileName)
UINT WINAPI GetSystemDirectoryW(OUT LPWSTR lpBuffer, IN UINT uSize)
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)
HANDLE WINAPI DECLSPEC_HOTPATCH CreateThread(IN LPSECURITY_ATTRIBUTES lpThreadAttributes, IN DWORD dwStackSize, IN LPTHREAD_START_ROUTINE lpStartAddress, IN LPVOID lpParameter, IN DWORD dwCreationFlags, OUT LPDWORD lpThreadId)
BOOL WINAPI SetLocalTime(IN CONST SYSTEMTIME *lpSystemTime)
VOID WINAPI GetLocalTime(OUT LPSYSTEMTIME lpSystemTime)
BOOL WINAPI WritePrivateProfileStringW(LPCWSTR section, LPCWSTR entry, LPCWSTR string, LPCWSTR filename)
INT WINAPI GetPrivateProfileStringW(LPCWSTR section, LPCWSTR entry, LPCWSTR def_val, LPWSTR buffer, UINT len, LPCWSTR filename)
HRSRC WINAPI FindResourceW(HINSTANCE hModule, LPCWSTR name, LPCWSTR type)
DWORD WINAPI SizeofResource(HINSTANCE hModule, HRSRC hRsrc)
LPVOID WINAPI LockResource(HGLOBAL handle)
HGLOBAL WINAPI LoadResource(HINSTANCE hModule, HRSRC hRsrc)
BOOL WINAPI SetTimeZoneInformation(CONST TIME_ZONE_INFORMATION *lpTimeZoneInformation)
GEOID WINAPI GetUserGeoID(GEOCLASS GeoClass)
LCID WINAPI GetThreadLocale(void)
INT WINAPI GetGeoInfoW(GEOID geoid, GEOTYPE geotype, LPWSTR data, int data_len, LANGID lang)
LCID WINAPI GetUserDefaultLCID(void)
LCID WINAPI GetSystemDefaultLCID(void)
INT WINAPI GetLocaleInfoW(LCID lcid, LCTYPE lctype, LPWSTR buffer, INT len)
ULONG WINAPI DECLSPEC_HOTPATCH GetTickCount(void)
_ACRTIMP wchar_t *__cdecl _ultow(__msvcrt_ulong, wchar_t *, int)
_ACRTIMP int __cdecl _wtoi(const wchar_t *)
_ACRTIMP int __cdecl _wcsicmp(const wchar_t *, const wchar_t *)
_ACRTIMP size_t __cdecl wcslen(const wchar_t *)
_ACRTIMP int __cdecl wcscmp(const wchar_t *, const wchar_t *)
_ACRTIMP int __cdecl rand(void)
_ACRTIMP void __cdecl srand(unsigned int)
static const WCHAR CmdLine[]
BOOL WINAPI SetupInstallFromInfSectionW(HWND owner, HINF hinf, PCWSTR section, UINT flags, HKEY key_root, PCWSTR src_root, UINT copy_flags, PSP_FILE_CALLBACK_W callback, PVOID context, HDEVINFO devinfo, PSP_DEVINFO_DATA devinfo_data)
static const WCHAR RegisterDlls[]
HINF WINAPI SetupOpenInfFileW(PCWSTR name, PCWSTR class, DWORD style, UINT *error)
LONG WINAPI SetupGetLineCountW(HINF hinf, PCWSTR section)
void WINAPI SetupTermDefaultQueueCallback(PVOID context)
PVOID WINAPI SetupInitDefaultQueueCallback(HWND owner)
HRESULT WINAPI SHGetFolderPathAndSubDirW(HWND hwndOwner, int nFolder, HANDLE hToken, DWORD dwFlags, LPCWSTR pszSubPath, LPWSTR pszPath)
NTSTATUS SetAdministratorPassword(LPCWSTR Password)
struct _ITEMSDATA * PITEMSDATA
LONG CountSecuritySteps(VOID)
struct _REGISTRATIONNOTIFY * PREGISTRATIONNOTIFY
DWORD InstallSecurity(_In_ PITEMSDATA pItemsData, _In_ PREGISTRATIONNOTIFY pNotify)
BOOL RegisterTypeLibraries(_In_ PITEMSDATA pItemsData, _In_ PREGISTRATIONNOTIFY pNotify, _In_ HINF hinf, _In_ LPCWSTR szSection)
VOID InstallStartMenuItems(_In_ PITEMSDATA pItemsData)
#define IDS_THEMESELECTIONTITLE
#define IDC_OWNERORGANIZATION
#define IDS_INSTALLATIONSERVERINFO
#define IDS_INSTALLATIONSUBTITLE
#define IDC_INSTALLATION_ICON
#define IDS_LOCALESUBTITLE
#define IDS_INSTALLATIONWORKSTATIONNAME
#define IDC_INSTALLATION_TYPES
#define IDC_ADMINPASSWORD2
#define IDS_DLLINSTALL_FAILED
#define IDS_REGSVR_FAILED
#define IDS_WZD_COMPUTERNAME
#define IDC_INSTALLATION_DESCRIPTION
#define IDS_LOADLIBRARY_FAILED
#define IDS_OWNERSUBTITLE
#define IDS_GETPROCADDR_FAILED
#define IDS_WZD_PASSWORDMATCH
#define IDS_COMPUTERSUBTITLE
#define IDS_INSTALLATIONTITLE
#define IDS_WZD_PASSWORDCHAR
#define IDS_DATETIMESUBTITLE
#define IDS_THEMESELECTIONSUBTITLE
#define IDS_REASON_UNKNOWN
#define IDS_INSTALLATIONSERVERNAME
#define IDS_COMPUTERTITLE
#define IDS_WZD_LOCALTIME
#define IDS_MACHINE_OWNER_NAME
#define IDS_WZD_SETCOMPUTERNAME
#define IDS_WZD_PASSWORDEMPTY
#define IDS_INSTALLATIONSERVERCORENAME
#define IDC_ADMINPASSWORD1
#define IDS_INSTALLATIONWORKSTATIONINFO
#define IDS_DATETIMETITLE
#define IDS_ADMINISTRATOR_NAME
#define IDS_INSTALLATIONSERVERCOREINFO
NTSTATUS WINAPI SetAccountsDomainSid(PSID DomainSid, LPCWSTR DomainName)
#define EnableDlgItem(hDlg, nID, bEnable)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
HLOCAL NTAPI LocalFree(HLOCAL hMem)
void WINAPI SHIM_OBJ_NAME() OutputDebugStringW(LPCWSTR lpOutputString)
#define EXCEPTION_EXECUTE_HANDLER
HRESULT Next([in] ULONG celt, [out, size_is(celt), length_is(*pceltFetched)] STATPROPSETSTG *rgelt, [out] ULONG *pceltFetched)
#define memcpy(s1, s2, n)
PSDBQUERYRESULT_VISTA PVOID DWORD * dwSize
#define _swprintf(buf, format,...)
static PLARGE_INTEGER Time
static SCRIPT_CACHE SCRIPT_ANALYSIS OPENTYPE_TAG OPENTYPE_TAG int TEXTRANGE_PROPERTIES int const WCHAR int cChars
unsigned __int3264 UINT_PTR
INT WINAPI MulDiv(INT nNumber, INT nNumerator, INT nDenominator)
static HFONT CreateTitleFont(VOID)
static INT_PTR CALLBACK WelcomeDlgProc(IN HWND hwndDlg, IN UINT uMsg, IN WPARAM wParam, IN LPARAM lParam)
static INT_PTR CALLBACK FinishDlgProc(IN HWND hwndDlg, IN UINT uMsg, IN WPARAM wParam, IN LPARAM lParam)
static VOID CenterWindow(IN HWND hWnd)
#define REG_OPTION_NON_VOLATILE
#define FILE_ATTRIBUTE_DIRECTORY
#define MAKELCID(lgid, srtid)
#define MAKEINTRESOURCE(i)
#define PathCanonicalizeW
#define PathAddBackslashW
static const WCHAR szName[]
#define PropSheet_PressButton(d, i)
#define CreatePropertySheetPage
#define PropSheet_SetWizButtons(d, f)
#define ListView_InsertItem(hwnd, pitem)
#define ListView_SetIconSpacing(hwndLV, cx, cy)
#define ListView_SetImageList(hwnd, himl, iImageList)
#define ListView_SetBkColor(hwnd, clrBk)
#define DateTime_SetSystemtime(hdp, gd, pst)
#define DTN_DATETIMECHANGE
struct tagNMLISTVIEW * LPNMLISTVIEW
#define ListView_SetTextBkColor(hwnd, clrTextBk)
#define DateTime_GetSystemtime(hdp, pst)
_In_opt_ _In_opt_ _In_ _In_ DWORD cbData
#define _SEH2_GetExceptionCode()
#define _SEH2_EXCEPT(...)
NTSTATUS NTAPI RtlCreateBootStatusDataFile(VOID)
#define SPREG_GETPROCADDR
#define SetupDefaultQueueCallback
#define SPFILENOTIFY_STARTREGISTRATION
struct _SP_REGISTER_CONTROL_STATUSW * PSP_REGISTER_CONTROL_STATUSW
#define SPFILENOTIFY_ENDREGISTRATION
#define SPREG_LOADLIBRARY
STDMETHOD() Next(THIS_ ULONG celt, IAssociationElement *pElement, ULONG *pceltFetched) PURE
STRSAFEAPI StringCchPrintfW(STRSAFE_LPWSTR pszDest, size_t cchDest, STRSAFE_LPCWSTR pszFormat,...)
STRSAFEAPI StringCchCatW(STRSAFE_LPWSTR pszDest, size_t cchDest, STRSAFE_LPCWSTR pszSrc)
STRSAFEAPI StringCbCopyW(STRSAFE_LPWSTR pszDest, size_t cbDest, STRSAFE_LPCWSTR pszSrc)
WCHAR lfFaceName[LF_FACESIZE]
DWORD ReportAsWorkstation
PREGISTRATIONNOTIFY pNotify
INSTALLATION_TYPE InstallationType
struct _TIMEZONE_ENTRY * TimeZoneListHead
UINT uPostNetworkWizardPage
struct _TIMEZONE_ENTRY * TimeZoneListTail
UINT uFirstNetworkWizardPage
WCHAR OwnerOrganization[51]
DWORD DisableAutoDaylightTimeSet
REG_TZI_FORMAT TimezoneInfo
struct _TIMEZONE_ENTRY * Prev
struct _TIMEZONE_ENTRY * Next
static BOOL WriteOwnerSettings(WCHAR *OwnerName, WCHAR *OwnerOrganization)
static VOID RegisterComponents(PITEMSDATA pItemsData)
static const WCHAR * s_ExplorerSoundEvents[][2]
static INT_PTR CALLBACK GplDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static BOOL DoWriteSoundEvents(HKEY hKey, LPCWSTR lpSubkey, LPCWSTR lpEventsArray[][2], DWORD dwSize)
struct _PRODUCT_OPTION_DATA PRODUCT_OPTION_DATA
static VOID ShowItemError(HWND hwndDlg, DWORD LastError)
struct _REGISTRATIONDATA REGISTRATIONDATA
static BOOL GetInstallSourceWin32(OUT PWSTR pwszPath, IN DWORD cchPathMax, IN PCWSTR pwszNTPath)
static const WCHAR s_szRosVersion[]
static BOOL RunItemCompletionThread(_In_ HWND hwndDlg)
static UINT CALLBACK RegistrationNotificationProc(PVOID Context, UINT Notification, UINT_PTR Param1, UINT_PTR Param2)
static VOID CreateTimeZoneList(PSETUPDATA SetupData)
VOID GetSetupInfPath(PWSTR szPath, UINT cchMax)
static VOID SetKeyboardLayoutName(HWND hwnd)
static BOOL SetSystemLocalTime(HWND hwnd, PSETUPDATA SetupData)
static VOID WriteUserLocale(VOID)
static INT_PTR CALLBACK ComputerPageDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static BOOL PathIsEqual(IN LPCWSTR lpPath1, IN LPCWSTR lpPath2)
static VOID UpdateLocalSystemTime(HWND hwnd, SYSTEMTIME LocalTime)
static INT_PTR CALLBACK LocalePageDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
VOID EnableVisualTheme(_In_opt_ HWND hwndParent, _In_opt_ PCWSTR ThemeFile)
static BOOL WriteDefaultLogonData(LPWSTR Domain)
static void GenerateComputerName(LPWSTR lpBuffer)
static PTIMEZONE_ENTRY GetLargerTimeZoneEntry(PSETUPDATA SetupData, DWORD Index)
static VOID SetUserLocaleName(HWND hwnd)
static INT_PTR CALLBACK OwnerPageDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static BOOL WriteDateTimeSettings(HWND hwndDlg, PSETUPDATA SetupData)
static INT_PTR CALLBACK DateTimePageDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static const WCHAR * InstallationTypes[INSTALLATION_TYPE_MAX]
static HFONT CreateBoldFont(VOID)
static BOOL WriteComputerSettings(WCHAR *ComputerName, HWND hwndDlg)
VOID ProcessSetupInf(IN OUT PSETUPDATA pSetupData)
static VOID ShowStepError(HWND hwndDlg, PREGISTRATIONNOTIFY RegistrationNotify)
static const WCHAR s_szWinlogon[]
static VOID DestroyTimeZoneList(PSETUPDATA SetupData)
static const PRODUCT_OPTION_DATA s_ProductOptionData[INSTALLATION_TYPE_MAX]
static const WCHAR * s_DefaultSoundEvents[][2]
static BOOL GetLocalSystemTime(HWND hwnd, PSETUPDATA SetupData)
static void OnChooseInstallationType(HWND hwndDlg, INSTALLATION_TYPE nOption)
static LONG RetrieveTimeZone(IN HKEY hZoneKey, IN PVOID Context)
static struct ThemeInfo Themes[]
DWORD(WINAPI * PFNREQUESTWIZARDPAGES)(PDWORD, HPROPSHEETPAGE *, PSETUPDATA)
static PTIMEZONE_ENTRY GetSelectedTimeZoneEntry(PSETUPDATA SetupData, DWORD dwEntryIndex)
static PTIMEZONE_ENTRY GetTimeZoneEntryByIndex(PSETUPDATA SetupData, DWORD dwComboIndex)
void WINAPI Control_RunDLLW(HWND hWnd, HINSTANCE hInst, LPCWSTR cmd, DWORD nCmdShow)
struct _REGISTRATIONDATA * PREGISTRATIONDATA
static VOID SetLocalTimeZone(HWND hwnd, PSETUPDATA SetupData)
static INT_PTR CALLBACK ThemePageDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static INT_PTR CALLBACK AckPageDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static BOOL HasDaylightSavingTime(PTIMEZONE_ENTRY Entry)
static DWORD CALLBACK ItemCompletionThread(LPVOID Parameter)
static BOOL RunControlPanelApplet(HWND hwnd, PCWSTR pwszCPLParameters)
static VOID SetInstallationCompleted(IN BOOL Unattended)
static const WCHAR s_szCurrentVersion[]
static VOID AddInstallationSource(IN HKEY hKey, IN LPWSTR lpPath)
struct _TIMEZONE_ENTRY * PTIMEZONE_ENTRY
static const WCHAR s_szExplorerSoundEvents[]
static INT_PTR CALLBACK InstallTypePageDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
VOID ProcessUnattendSection(IN OUT PSETUPDATA pSetupData)
static BOOL DoWriteInstallationType(INSTALLATION_TYPE nOption)
static VOID UpdateAutoDaylightCheckbox(HWND hwndDlg, PTIMEZONE_ENTRY Entry)
struct _TIMEZONE_ENTRY TIMEZONE_ENTRY
static const WCHAR s_szProductOptions[]
static const WCHAR s_szControlWindows[]
static VOID ShowTimeZoneList(HWND hwnd, PSETUPDATA SetupData, DWORD dwEntryIndex)
static INT_PTR CALLBACK ProcessPageDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static const WCHAR s_szDefaultSoundEvents[]
#define LogItem(lpTag, lpMessageText...)
@ INSTALLATION_TYPE_SERVER_CORE
@ INSTALLATION_TYPE_DEFAULT
@ INSTALLATION_TYPE_SERVER
@ INSTALLATION_TYPE_WORKSTATION
enum _INSTALLATION_TYPE INSTALLATION_TYPE
TW_UINT32 TW_UINT16 TW_UINT16 TW_MEMREF pData
TW_UINT32 TW_UINT16 TW_UINT16 MSG
VOID EnumerateTimeZoneList(IN PENUM_TIMEZONE_CALLBACK Callback, IN PVOID Context OPTIONAL)
LONG QueryTimeZoneData(IN HKEY hZoneKey, OUT PULONG Index OPTIONAL, OUT PREG_TZI_FORMAT TimeZoneInfo, OUT PWCHAR Description OPTIONAL, IN OUT PULONG DescriptionSize OPTIONAL, OUT PWCHAR StandardName OPTIONAL, IN OUT PULONG StandardNameSize OPTIONAL, OUT PWCHAR DaylightName OPTIONAL, IN OUT PULONG DaylightNameSize OPTIONAL)
VOID SetAutoDaylight(IN BOOL EnableAutoDaylightTime)
BOOL GetTimeZoneListIndex(IN OUT PULONG pIndex)
BOOL WINAPI SetupGetStringFieldW(IN PINFCONTEXT Context, IN ULONG FieldIndex, OUT PWSTR ReturnBuffer, IN ULONG ReturnBufferSize, OUT PULONG RequiredSize)
BOOL WINAPI SetupFindFirstLineW(IN HINF InfHandle, IN PCWSTR Section, IN PCWSTR Key, IN OUT PINFCONTEXT Context)
BOOL WINAPI SetupFindNextLine(IN PINFCONTEXT ContextIn, OUT PINFCONTEXT ContextOut)
VOID WINAPI SetupCloseInfFile(IN HINF InfHandle)
struct _THEME_FILE THEME_FILE
#define INVALID_FILE_ATTRIBUTES
_In_ WDFCOLLECTION _In_ ULONG Index
_In_ PWDFDEVICE_INIT _In_ PFN_WDF_DEVICE_SHUTDOWN_NOTIFICATION Notification
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_DEVICE_PROPERTY_DATA _In_ DEVPROPTYPE _In_ ULONG Size
HRESULT RunCommandAndWait(_In_ PWCHAR Command)
HRESULT InstallOptionalComponents(_In_ PITEMSDATA pItemsData)
BOOL WINAPI EnumDisplaySettingsW(LPCWSTR lpszDeviceName, DWORD iModeNum, LPDEVMODEW lpDevMode)
LONG WINAPI ChangeDisplaySettingsW(LPDEVMODEW lpDevMode, DWORD dwflags)
UINT WINAPI GetDlgItemTextW(HWND hDlg, int nIDDlgItem, LPWSTR lpString, int nMaxCount)
VOID WINAPI SwitchToThisWindow(HWND hwnd, BOOL fAltTab)
DWORD WINAPI GetLastError(void)
#define FORMAT_MESSAGE_FROM_SYSTEM
#define FORMAT_MESSAGE_ALLOCATE_BUFFER
#define MAX_COMPUTERNAME_LENGTH
#define ListBox_AddString(hwndCtl, lpsz)
NTSYSAPI ULONG WINAPI RtlNtStatusToDosError(NTSTATUS)
#define DM_DISPLAYFREQUENCY
int WINAPI GetDeviceCaps(_In_opt_ HDC, _In_ int)
HFONT WINAPI CreateFontIndirectW(_In_ const LOGFONTW *)
#define HKEY_LOCAL_MACHINE
#define HKEY_CURRENT_USER
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
BOOL WINAPI TranslateMessage(_In_ const MSG *)
BOOL WINAPI ShowWindow(_In_ HWND, _In_ int)
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)
__analysis_noreturn void WINAPI PostQuitMessage(_In_ int)
#define LR_CREATEDIBSECTION
BOOL WINAPI SetForegroundWindow(_In_ HWND)
HANDLE WINAPI LoadImageW(_In_opt_ HINSTANCE hInst, _In_ LPCWSTR name, _In_ UINT type, _In_ int cx, _In_ int cy, _In_ UINT fuLoad)
LRESULT WINAPI SendMessageA(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI SetDlgItemTextW(_In_ HWND, _In_ int, _In_ LPCWSTR)
#define QS_ALLPOSTMESSAGE
#define CDS_UPDATEREGISTRY
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)
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
UINT_PTR WINAPI SetTimer(_In_opt_ HWND, _In_ UINT_PTR, _In_ UINT, _In_opt_ TIMERPROC)
LRESULT WINAPI SendDlgItemMessageW(_In_ HWND, _In_ int, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
HWND WINAPI GetDesktopWindow(void)
BOOL WINAPI SetWindowTextW(_In_ HWND, _In_opt_ LPCWSTR)
#define ENUM_CURRENT_SETTINGS
HWND WINAPI SetFocus(_In_opt_ HWND)
BOOL WINAPI PeekMessageW(_Out_ LPMSG, _In_opt_ HWND, _In_ UINT, _In_ UINT, _In_ UINT)
struct tagNMHDR * LPNMHDR
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
HDC WINAPI GetDC(_In_opt_ HWND)
HWND WINAPI GetParent(_In_ HWND)
LRESULT WINAPI DispatchMessageW(_In_ const MSG *)
#define MAKEINTRESOURCEW(i)
BOOL WINAPI KillTimer(_In_opt_ HWND, _In_ UINT_PTR)
#define SendDlgItemMessage
BOOL WINAPI DestroyWindow(_In_ HWND)
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI EndDialog(_In_ HWND, _In_ INT_PTR)
BOOL WINAPI DestroyIcon(_In_ HICON)
_Inout_opt_ PVOID Parameter