From fc44080110192d0fb8afb61308a98d5a18406a3d Mon Sep 17 00:00:00 2001 From: Pete Batard Date: Mon, 25 Nov 2013 22:34:26 +0000 Subject: [PATCH] [misc] improve cheat modes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Alt-F usage was not reflected on the UI (suggested by José Pineda) * Alt-L usage was not reflected on the UI * Also update ChangeLog.txt for BETA 2 --- ChangeLog.txt | 3 ++- src/rufus.c | 10 ++++++---- src/rufus.rc | 10 +++++----- 3 files changed, 13 insertions(+), 10 deletions(-) diff --git a/ChangeLog.txt b/ChangeLog.txt index f2d7ccc4..0a0dc6d0 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -4,6 +4,7 @@ o Version 1.4.0 (2013.12.??) - German, courtesy of Thilo Langbein - Hugarian, courtesy of georg1136 - Italian, courtesy of bovirus + - Korean, courtesy of NaJiyoun - Romanian, courtesy of Gîrlea Alexandru - Russian, courtesy of Кирилл Иванов - Spanish, courtesy of José Pineda @@ -14,7 +15,7 @@ o Version 1.4.0 (2013.12.??) Add detection and display VID:PID for the target device (in the log) Updated Syslinux to v4.0.7 Fixed some issues with DOS localization - Fixed FAT32 formatting for large disks + Fixed FAT32 formatting for large and GPT disks Fixed support for Ubuntu, Scientific Linux, unofficial Windows and other ISOs o Version 1.3.4 (2013.07.15) Syslinux v5 support (NEW) diff --git a/src/rufus.c b/src/rufus.c index c6083c73..f0ae0ad7 100644 --- a/src/rufus.c +++ b/src/rufus.c @@ -292,7 +292,7 @@ out: if (SelectedDrive.ClusterSize[fs].Allowed != 0) { tmp[0] = 0; // Tell the user if we're going to use Large FAT32 or regular - if ((fs == FS_FAT32) && (SelectedDrive.DiskSize > LARGE_FAT32_SIZE)) + if ((fs == FS_FAT32) && ((SelectedDrive.DiskSize > LARGE_FAT32_SIZE) || (force_large_fat32))) safe_strcat(tmp, sizeof(tmp), "Large "); safe_strcat(tmp, sizeof(tmp), FileSystemLabel[fs]); if (default_fs == FS_UNKNOWN) { @@ -835,7 +835,7 @@ static void InitProgress(void) nb_slots[OP_CREATE_FS] = nb_steps[ComboBox_GetItemData(hFileSystem, ComboBox_GetCurSel(hFileSystem))]; if ( (!IsChecked(IDC_QUICKFORMAT)) - || ((fs == FS_FAT32) && (SelectedDrive.DiskSize >= LARGE_FAT32_SIZE)) ) { + || ((fs == FS_FAT32) && ((SelectedDrive.DiskSize >= LARGE_FAT32_SIZE) || (force_large_fat32))) ) { nb_slots[OP_FORMAT] = -1; } nb_slots[OP_FINALIZE] = ((dt == DT_ISO) && (fs == FS_NTFS))?3:2; @@ -1698,7 +1698,7 @@ static INT_PTR CALLBACK MainCallback(HWND hDlg, UINT message, WPARAM wParam, LPA bt = GETBIOSTYPE((int)ComboBox_GetItemData(hPartitionScheme, ComboBox_GetCurSel(hPartitionScheme))); SetClusterSizes(fs); // Disable/restore the quick format control depending on large FAT32 - if ((fs == FS_FAT32) && (SelectedDrive.DiskSize > LARGE_FAT32_SIZE)) { + if ((fs == FS_FAT32) && ((SelectedDrive.DiskSize > LARGE_FAT32_SIZE) || (force_large_fat32))) { if (IsWindowEnabled(GetDlgItem(hMainDialog, IDC_QUICKFORMAT))) { uQFChecked = IsDlgButtonChecked(hMainDialog, IDC_QUICKFORMAT); CheckDlgButton(hMainDialog, IDC_QUICKFORMAT, BST_CHECKED); @@ -2168,18 +2168,20 @@ relaunch: } // Alt-F => Toggle detection of USB HDDs // By default Rufus does not list USB HDDs. This is a safety feature aimed at avoiding - // unintentional formattings of backup drives instead of USB keys. + // unintentional formatting of backup drives instead of USB keys. // When enabled, Rufus will list and allow the formatting of USB HDDs. if ((msg.message == WM_SYSKEYDOWN) && (msg.wParam == 'F')) { enable_HDDs = !enable_HDDs; PrintStatus2000(lmprintf(MSG_253), enable_HDDs); GetUSBDevices(0); + CheckDlgButton(hMainDialog, IDC_ENABLE_FIXED_DISKS, enable_HDDs?BST_CHECKED:BST_UNCHECKED); continue; } // Alt-L => Force Large FAT32 format to be used on < 32 GB drives if ((msg.message == WM_SYSKEYDOWN) && (msg.wParam == 'L')) { force_large_fat32 = !force_large_fat32; PrintStatus2000(lmprintf(MSG_254), force_large_fat32); + GetUSBDevices(0); continue; } // Alt-D => Delete the NoDriveTypeAutorun key on exit (useful if the app crashed) diff --git a/src/rufus.rc b/src/rufus.rc index 27e4e67b..d3b43348 100644 --- a/src/rufus.rc +++ b/src/rufus.rc @@ -33,7 +33,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL IDD_DIALOG DIALOGEX 12, 12, 206, 329 STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU EXSTYLE WS_EX_APPWINDOW -CAPTION "Rufus v1.4.0.330" +CAPTION "Rufus v1.4.0.331" FONT 8, "MS Shell Dlg", 400, 0, 0x1 BEGIN DEFPUSHBUTTON "Start",IDC_START,94,291,50,14 @@ -288,8 +288,8 @@ END // VS_VERSION_INFO VERSIONINFO - FILEVERSION 1,4,0,330 - PRODUCTVERSION 1,4,0,330 + FILEVERSION 1,4,0,331 + PRODUCTVERSION 1,4,0,331 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -306,13 +306,13 @@ BEGIN BEGIN VALUE "CompanyName", "Akeo Consulting (http://akeo.ie)" VALUE "FileDescription", "Rufus" - VALUE "FileVersion", "1.4.0.330" + VALUE "FileVersion", "1.4.0.331" VALUE "InternalName", "Rufus" VALUE "LegalCopyright", "© 2011-2013 Pete Batard (GPL v3)" VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/gpl.html" VALUE "OriginalFilename", "rufus.exe" VALUE "ProductName", "Rufus" - VALUE "ProductVersion", "1.4.0.330" + VALUE "ProductVersion", "1.4.0.331" END END BLOCK "VarFileInfo"