mirror of
https://github.com/pbatard/rufus.git
synced 2026-10-24 02:28:58 +03:00
[wue] fix silent option being potentially applied when its dependencies aren't met
* Also add a warning sign to the log report when the option is used. * Closes #3008.
This commit is contained in:
10
src/rufus.rc
10
src/rufus.rc
@@ -33,7 +33,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
|
||||
IDD_DIALOG DIALOGEX 12, 12, 232, 326
|
||||
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||
EXSTYLE WS_EX_ACCEPTFILES
|
||||
CAPTION "Rufus 4.15.2400"
|
||||
CAPTION "Rufus 4.15.2401"
|
||||
FONT 9, "Segoe UI Symbol", 400, 0, 0x0
|
||||
BEGIN
|
||||
LTEXT "Drive Properties",IDS_DRIVE_PROPERTIES_TXT,8,6,53,12,NOT WS_GROUP
|
||||
@@ -409,8 +409,8 @@ END
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 4,15,2400,0
|
||||
PRODUCTVERSION 4,15,2400,0
|
||||
FILEVERSION 4,15,2401,0
|
||||
PRODUCTVERSION 4,15,2401,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
@@ -428,13 +428,13 @@ BEGIN
|
||||
VALUE "Comments", "https://rufus.ie"
|
||||
VALUE "CompanyName", "Akeo Consulting"
|
||||
VALUE "FileDescription", "Rufus"
|
||||
VALUE "FileVersion", "4.15.2400"
|
||||
VALUE "FileVersion", "4.15.2401"
|
||||
VALUE "InternalName", "Rufus"
|
||||
VALUE "LegalCopyright", "© 2011-2026 Pete Batard (GPL v3)"
|
||||
VALUE "LegalTrademarks", "https://www.gnu.org/licenses/gpl-3.0.html"
|
||||
VALUE "OriginalFilename", "rufus-4.15.exe"
|
||||
VALUE "ProductName", "Rufus"
|
||||
VALUE "ProductVersion", "4.15.2400"
|
||||
VALUE "ProductVersion", "4.15.2401"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
|
||||
@@ -1080,8 +1080,8 @@ static INT_PTR CALLBACK SelectionCallback(HWND hDlg, UINT message, WPARAM wParam
|
||||
} else switch (LOWORD(wParam)) {
|
||||
case IDOK:
|
||||
// Produce a big scary warning if the silent install option was selected
|
||||
if (selection_data[s].options->edition_index > 0 &&
|
||||
Button_GetCheck(GetDlgItem(hDlg, IDC_SELECTION_CHOICE1 + selection_data[s].options->edition_index - 1))) {
|
||||
hCtrl = GetDlgItem(hDlg, IDC_SELECTION_CHOICE1 + selection_data[s].options->edition_index - 1);
|
||||
if (selection_data[s].options->edition_index > 0 && IsWindowVisible(hCtrl) && Button_GetCheck(hCtrl)) {
|
||||
selection_dialog_options_t selection = { 0 };
|
||||
selection.style = BS_AUTOCHECKBOX;
|
||||
selection.flags = SELECTION_NEEDS_ALL_TO_PROCEED | SELECTION_USE_WARNING_ICON;
|
||||
@@ -1095,7 +1095,8 @@ static INT_PTR CALLBACK SelectionCallback(HWND hDlg, UINT message, WPARAM wParam
|
||||
break;
|
||||
}
|
||||
for (r = 0, i = 0, m = 1; i < nDialogItems; i++, m <<= 1)
|
||||
if (Button_GetCheck(GetDlgItem(hDlg, IDC_SELECTION_CHOICE1 + i)) == BST_CHECKED)
|
||||
if (Button_GetCheck(GetDlgItem(hDlg, IDC_SELECTION_CHOICE1 + i)) == BST_CHECKED &&
|
||||
IsWindowVisible(GetDlgItem(hDlg, IDC_SELECTION_CHOICE1 + i)))
|
||||
r += m;
|
||||
if (selection_data[s].options->username_index > 0) {
|
||||
GetWindowTextU(GetDlgItem(hDlg, IDC_SELECTION_USERNAME), unattend_username, MAX_USERNAME_LENGTH);
|
||||
|
||||
@@ -150,7 +150,7 @@ char* CreateUnattendXml(int arch, int flags)
|
||||
fprintf(fd, " </ProductKey>\n");
|
||||
fprintf(fd, " </UserData>\n");
|
||||
if (flags & UNATTEND_SILENT_INSTALL) {
|
||||
uprintf("• Silent Install");
|
||||
uprintf("• ⚠Silent Install⚠");
|
||||
// Automatically partition the disk and set the installation target
|
||||
fprintf(fd, " <DiskConfiguration>\n");
|
||||
fprintf(fd, " <WillShowUI>OnError</WillShowUI>\n");
|
||||
|
||||
Reference in New Issue
Block a user