mirror of
https://github.com/pbatard/rufus.git
synced 2024-08-14 23:57:05 +00:00
[ui] fix quickformat option being ignored when unchecked
This commit is contained in:
parent
078aaf7714
commit
555397403a
2 changed files with 13 additions and 9 deletions
12
src/rufus.c
12
src/rufus.c
|
@ -697,15 +697,19 @@ static void EnableQuickFormat(BOOL enable)
|
||||||
{
|
{
|
||||||
HWND hCtrl = GetDlgItem(hMainDialog, IDC_QUICK_FORMAT);
|
HWND hCtrl = GetDlgItem(hMainDialog, IDC_QUICK_FORMAT);
|
||||||
|
|
||||||
|
// Keep track of the current state if we are going to disable it
|
||||||
|
if (IsWindowEnabled(hCtrl) && !enable) {
|
||||||
|
uQFChecked = IsChecked(IDC_QUICK_FORMAT);
|
||||||
|
}
|
||||||
|
|
||||||
// Disable/restore the quick format control depending on large FAT32 or ReFS
|
// Disable/restore the quick format control depending on large FAT32 or ReFS
|
||||||
if (((fs == FS_FAT32) && ((SelectedDrive.DiskSize > LARGE_FAT32_SIZE) || (force_large_fat32))) || (fs == FS_REFS)) {
|
if (((fs == FS_FAT32) && ((SelectedDrive.DiskSize > LARGE_FAT32_SIZE) || (force_large_fat32))) || (fs == FS_REFS)) {
|
||||||
enable = FALSE;
|
enable = FALSE;
|
||||||
|
CheckDlgButton(hMainDialog, IDC_QUICK_FORMAT, BST_CHECKED);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (IsWindowEnabled(hCtrl) && !enable) {
|
// Restore state if we are re-enabling the control
|
||||||
uQFChecked = IsChecked(IDC_QUICK_FORMAT);
|
if (!IsWindowEnabled(hCtrl) && enable) {
|
||||||
CheckDlgButton(hMainDialog, IDC_QUICK_FORMAT, BST_CHECKED);
|
|
||||||
} else if (!IsWindowEnabled(hCtrl) && enable) {
|
|
||||||
CheckDlgButton(hMainDialog, IDC_QUICK_FORMAT, uQFChecked);
|
CheckDlgButton(hMainDialog, IDC_QUICK_FORMAT, uQFChecked);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
10
src/rufus.rc
10
src/rufus.rc
|
@ -33,7 +33,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
|
||||||
IDD_DIALOG DIALOGEX 12, 12, 232, 326
|
IDD_DIALOG DIALOGEX 12, 12, 232, 326
|
||||||
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||||
EXSTYLE WS_EX_ACCEPTFILES
|
EXSTYLE WS_EX_ACCEPTFILES
|
||||||
CAPTION "Rufus 3.5.1445"
|
CAPTION "Rufus 3.5.1446"
|
||||||
FONT 9, "Segoe UI Symbol", 400, 0, 0x0
|
FONT 9, "Segoe UI Symbol", 400, 0, 0x0
|
||||||
BEGIN
|
BEGIN
|
||||||
LTEXT "Drive Properties",IDS_DRIVE_PROPERTIES_TXT,8,6,53,12,NOT WS_GROUP
|
LTEXT "Drive Properties",IDS_DRIVE_PROPERTIES_TXT,8,6,53,12,NOT WS_GROUP
|
||||||
|
@ -394,8 +394,8 @@ END
|
||||||
//
|
//
|
||||||
|
|
||||||
VS_VERSION_INFO VERSIONINFO
|
VS_VERSION_INFO VERSIONINFO
|
||||||
FILEVERSION 3,5,1445,0
|
FILEVERSION 3,5,1446,0
|
||||||
PRODUCTVERSION 3,5,1445,0
|
PRODUCTVERSION 3,5,1446,0
|
||||||
FILEFLAGSMASK 0x3fL
|
FILEFLAGSMASK 0x3fL
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
FILEFLAGS 0x1L
|
FILEFLAGS 0x1L
|
||||||
|
@ -413,13 +413,13 @@ BEGIN
|
||||||
VALUE "Comments", "https://akeo.ie"
|
VALUE "Comments", "https://akeo.ie"
|
||||||
VALUE "CompanyName", "Akeo Consulting"
|
VALUE "CompanyName", "Akeo Consulting"
|
||||||
VALUE "FileDescription", "Rufus"
|
VALUE "FileDescription", "Rufus"
|
||||||
VALUE "FileVersion", "3.5.1445"
|
VALUE "FileVersion", "3.5.1446"
|
||||||
VALUE "InternalName", "Rufus"
|
VALUE "InternalName", "Rufus"
|
||||||
VALUE "LegalCopyright", "© 2011-2018 Pete Batard (GPL v3)"
|
VALUE "LegalCopyright", "© 2011-2018 Pete Batard (GPL v3)"
|
||||||
VALUE "LegalTrademarks", "https://www.gnu.org/copyleft/gpl.html"
|
VALUE "LegalTrademarks", "https://www.gnu.org/copyleft/gpl.html"
|
||||||
VALUE "OriginalFilename", "rufus-3.5.exe"
|
VALUE "OriginalFilename", "rufus-3.5.exe"
|
||||||
VALUE "ProductName", "Rufus"
|
VALUE "ProductName", "Rufus"
|
||||||
VALUE "ProductVersion", "3.5.1445"
|
VALUE "ProductVersion", "3.5.1446"
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
BLOCK "VarFileInfo"
|
BLOCK "VarFileInfo"
|
||||||
|
|
Loading…
Reference in a new issue