mirror of
				https://github.com/pbatard/rufus.git
				synced 2024-08-14 23:57:05 +00:00 
			
		
		
		
	UI redesign, part 10
* "It's when you start to see the light at the end of the tunnel..."
This commit is contained in:
		
							parent
							
								
									091aa93cf6
								
							
						
					
					
						commit
						b0529e1eb0
					
				
					 11 changed files with 440 additions and 1434 deletions
				
			
		|  | @ -16,9 +16,44 @@ translation, but always use the English section of rufus.loc as your base. | ||||||
| For instance, MSG_114, that was introduced in v1.0.8 is MORE than one line! | For instance, MSG_114, that was introduced in v1.0.8 is MORE than one line! | ||||||
| 
 | 
 | ||||||
| o Version 1.0.23 (2018.??.??) | o Version 1.0.23 (2018.??.??) | ||||||
|   - Changed MSG_280 "Image selection" -> "Disk or ISO image" |   - All positioning ('m', 's') has now been removed as well as some controls, for the 3.0 UI redesign | ||||||
|   - Changed MSG_281 "(Please select an image)" -> "%s (Please select)" |   - Removed: MSG_086, MSG_087, MSG_163 | ||||||
|  |   - *NEW*      IDS_DRIVE_PROPERTIES_TXT "Drive Properties" | ||||||
|  |   - *NEW*      IDS_BOOT_TYPE_TXT "Boot selection" | ||||||
|  |   - *NEW*      IDC_SELECT "SELECT" | ||||||
|  |   - *NEW*      IDS_IMAGE_OPTION_TXT "Image Option" | ||||||
|  |   - *UPDATED*  IDS_PARTITION_TYPE_TXT Partition scheme and target system type -> "Partition scheme" | ||||||
|  |   - *NEW*      IDS_TARGET_SYSTEM_TXT "Target system" | ||||||
|  |   - *NEW*      IDS_STATUS_TXT "Status" | ||||||
|  |   - *REPLACED* MSG_031 -> "BIOS (or UEFI-CSM)" | ||||||
|  |   - *REPLACED* MSG_032 -> "UEFI (non CSM)" | ||||||
|  |   - *REPLACED* MSG_033 -> "BIOS or UEFI"  | ||||||
|  |   - *REMOVED*  MSG_086 | ||||||
|  |   - *REMOVED*  MSG_087 | ||||||
|  | 	- *RENAMED*  IDC_WINDOWS_INSTALL -> MSG_117 | ||||||
|  | 	- *RENAMED*  IDC_WINDOWS_TO_GO -> MSG_118 | ||||||
|  |   - *NEW*      MSG_119 "advanced drive properties" | ||||||
|  |   - *NEW*      MSG_120 "advanced format options" | ||||||
|  |   - *NEW*      MSG_121 "Show %s" | ||||||
|  |   - *NEW*      MSG_122 "Hide %s" | ||||||
|  |      MSG_119/120 + MSG_121/122 are used to create the advanced options clickable toolbars | ||||||
|  |   - *REPLACED* MSG_150 -> "Method that will be used to create partitions." | ||||||
|  |   - *REPLACED* MSG_151 -> "Type of computer you plan to use this bootable drive with. It is up to YOU to find whether your target is of BIOS or UEFI type.\n" | ||||||
|  | 	                        "Be mindful that CSM, which can be enabled or disabled on UEFI computers, means 'BIOS emulation', and is not really UEFI." | ||||||
|  |   - *REPLACED* MSG_152 -> "Note: 'UEFI-CSM' means BIOS emulation under UEFI, and is not the same as genuine UEFI."ement UEFI." | ||||||
|  |   - *REPLACED* MSG_280 "Image selection" -> "Disk or ISO image" | ||||||
|  |   - *REPLACED* MSG_281 "(Please select an image)" -> "%s (Please select)" | ||||||
|      MSG_281 + MSG_280 are used to create the message that appears in the boot selection dropdown when an image has not been selected. |      MSG_281 + MSG_280 are used to create the message that appears in the boot selection dropdown when an image has not been selected. | ||||||
|  |   - *NEW*      MSG_299 "Timestamp validation error" | ||||||
|  |   - *NEW*      MSG_300 "Rufus could not validate that the timestamp of the downloaded update is more recent than the one for the " | ||||||
|  | 	                     "current executable.\n\nIn order to prevent potential attack scenarios, the update process has been aborted and " | ||||||
|  | 	                     "the download will be deleted. Please check the log for more details." | ||||||
|  | 	- *NEW*      MSG_301 "Show application settings" | ||||||
|  |   - *NEW*      MSG_302 "Show information about this application" | ||||||
|  |   - *NEW*      MSG_303 "Show the log" | ||||||
|  |   - *NEW*      MSG_314 "Create a disk image of the selected device" | ||||||
|  |   - *UPDATED*  On IDD_LOG, IDC_LOG_CLEAR, IDC_LOG_SAVE and IDCANCEL were updated to remove the redundant mention of "Log" in the buttons | ||||||
|  |                for the languages who did that. *PLEASE* verify that the modification looks correct in your language. | ||||||
| 
 | 
 | ||||||
| o Version 1.0.22 (2017.07.17) | o Version 1.0.22 (2017.07.17) | ||||||
|   - *NEW* MSG_295 "Warning: Unofficial version" |   - *NEW* MSG_295 "Warning: Unofficial version" | ||||||
|  |  | ||||||
										
											
												File diff suppressed because it is too large
												Load diff
											
										
									
								
							|  | @ -1656,7 +1656,8 @@ DWORD WINAPI FormatThread(void* param) | ||||||
| 	char grub4dos_dst[] = "?:\\grldr"; | 	char grub4dos_dst[] = "?:\\grldr"; | ||||||
| 
 | 
 | ||||||
| 	use_large_fat32 = (fs == FS_FAT32) && ((SelectedDrive.DiskSize > LARGE_FAT32_SIZE) || (force_large_fat32)); | 	use_large_fat32 = (fs == FS_FAT32) && ((SelectedDrive.DiskSize > LARGE_FAT32_SIZE) || (force_large_fat32)); | ||||||
| 	windows_to_go = (togo_mode) && HAS_WINTOGO(img_report) && (Button_GetCheck(GetDlgItem(hMainDialog, IDC_WINDOWS_TO_GO)) == BST_CHECKED); | 	windows_to_go = display_togo_option && (bt == BT_IMAGE) && HAS_WINTOGO(img_report) && | ||||||
|  | 		(ComboBox_GetCurSel(GetDlgItem(hMainDialog, IDC_IMAGE_OPTION)) == 1); | ||||||
| 	large_drive = (SelectedDrive.DiskSize > (1*TB)); | 	large_drive = (SelectedDrive.DiskSize > (1*TB)); | ||||||
| 	if (large_drive) | 	if (large_drive) | ||||||
| 		uprintf("Notice: Large drive detected (may produce short writes)"); | 		uprintf("Notice: Large drive detected (may produce short writes)"); | ||||||
|  |  | ||||||
|  | @ -71,8 +71,6 @@ const loc_control_id control_id[] = { | ||||||
| 	LOC_CTRL(IDC_NOTIFICATION_LINE), | 	LOC_CTRL(IDC_NOTIFICATION_LINE), | ||||||
| 	LOC_CTRL(IDC_ADVANCED_DEVICE_TOOLBAR), | 	LOC_CTRL(IDC_ADVANCED_DEVICE_TOOLBAR), | ||||||
| 	LOC_CTRL(IDC_ADVANCED_FORMAT_TOOLBAR), | 	LOC_CTRL(IDC_ADVANCED_FORMAT_TOOLBAR), | ||||||
| 	LOC_CTRL(IDC_WINDOWS_INSTALL), |  | ||||||
| 	LOC_CTRL(IDC_WINDOWS_TO_GO), |  | ||||||
| 	LOC_CTRL(IDC_CHECKSUM_TOOLBAR), | 	LOC_CTRL(IDC_CHECKSUM_TOOLBAR), | ||||||
| 	LOC_CTRL(IDC_MULTI_TOOLBAR), | 	LOC_CTRL(IDC_MULTI_TOOLBAR), | ||||||
| 	LOC_CTRL(IDC_LANG), | 	LOC_CTRL(IDC_LANG), | ||||||
|  |  | ||||||
|  | @ -437,6 +437,19 @@ static __inline int ComboBox_GetLBTextU(HWND hCtrl, int index, char* lpString) | ||||||
| 	return size; | 	return size; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | static __inline DWORD CharUpperBuffU(char* lpString, DWORD len) | ||||||
|  | { | ||||||
|  | 	DWORD ret; | ||||||
|  | 	wchar_t *wlpString = calloc(len, sizeof(wchar_t)); | ||||||
|  | 	if (wlpString == NULL) | ||||||
|  | 		return 0; | ||||||
|  | 	utf8_to_wchar_no_alloc(lpString, wlpString, len); | ||||||
|  | 	ret = CharUpperBuffW(wlpString, len); | ||||||
|  | 	wchar_to_utf8_no_alloc(wlpString, lpString, len); | ||||||
|  | 	free(wlpString); | ||||||
|  | 	return ret; | ||||||
|  | } | ||||||
|  | 
 | ||||||
| static __inline HANDLE CreateFileU(const char* lpFileName, DWORD dwDesiredAccess, DWORD dwShareMode, | static __inline HANDLE CreateFileU(const char* lpFileName, DWORD dwDesiredAccess, DWORD dwShareMode, | ||||||
| 								   LPSECURITY_ATTRIBUTES lpSecurityAttributes, DWORD dwCreationDisposition, | 								   LPSECURITY_ATTRIBUTES lpSecurityAttributes, DWORD dwCreationDisposition, | ||||||
| 								   DWORD dwFlagsAndAttributes,  HANDLE hTemplateFile) | 								   DWORD dwFlagsAndAttributes,  HANDLE hTemplateFile) | ||||||
|  |  | ||||||
|  | @ -107,8 +107,6 @@ | ||||||
| #define IDC_NOTIFICATION_LINE           1042 | #define IDC_NOTIFICATION_LINE           1042 | ||||||
| #define IDC_ADVANCED_DEVICE_TOOLBAR     1043 | #define IDC_ADVANCED_DEVICE_TOOLBAR     1043 | ||||||
| #define IDC_ADVANCED_FORMAT_TOOLBAR     1044 | #define IDC_ADVANCED_FORMAT_TOOLBAR     1044 | ||||||
| #define IDC_WINDOWS_INSTALL             1047 |  | ||||||
| #define IDC_WINDOWS_TO_GO               1048 |  | ||||||
| #define IDC_CHECKSUM_TOOLBAR            1049 | #define IDC_CHECKSUM_TOOLBAR            1049 | ||||||
| #define IDC_MULTI_TOOLBAR               1050 | #define IDC_MULTI_TOOLBAR               1050 | ||||||
| #define IDC_LANG                        1051 | #define IDC_LANG                        1051 | ||||||
|  |  | ||||||
							
								
								
									
										136
									
								
								src/rufus.c
									
										
									
									
									
								
							
							
						
						
									
										136
									
								
								src/rufus.c
									
										
									
									
									
								
							|  | @ -69,7 +69,7 @@ static int64_t last_iso_blocking_status; | ||||||
| static int selection_default, row_height, advanced_device_section_height, advanced_format_section_height, image_index; | static int selection_default, row_height, advanced_device_section_height, advanced_format_section_height, image_index; | ||||||
| static int device_vpos, format_vpos, status_vpos; | static int device_vpos, format_vpos, status_vpos; | ||||||
| static int bw, hw, fw;	// Main button width, half dropdown width, full dropdown width
 | static int bw, hw, fw;	// Main button width, half dropdown width, full dropdown width
 | ||||||
| static int cb_width, dd_width, sw, mw, bsw, hbw, sbw, ssw; | static int sw, mw, bsw, hbw, sbw, ssw; | ||||||
| static UINT_PTR UM_LANGUAGE_MENU_MAX = UM_LANGUAGE_MENU; | static UINT_PTR UM_LANGUAGE_MENU_MAX = UM_LANGUAGE_MENU; | ||||||
| static RECT relaunch_rc = { -65536, -65536, 0, 0}; | static RECT relaunch_rc = { -65536, -65536, 0, 0}; | ||||||
| static UINT uQFChecked = BST_CHECKED, uMBRChecked = BST_UNCHECKED; | static UINT uQFChecked = BST_CHECKED, uMBRChecked = BST_UNCHECKED; | ||||||
|  | @ -81,6 +81,7 @@ static HICON hIconSave, hIconDown, hIconUp, hIconLang, hIconAbout, hIconSettings | ||||||
| static char szTimer[12] = "00:00:00"; | static char szTimer[12] = "00:00:00"; | ||||||
| static wchar_t wtbtext[2][128]; | static wchar_t wtbtext[2][128]; | ||||||
| static unsigned int timer; | static unsigned int timer; | ||||||
|  | static char uppercase_select[64], uppercase_start[64], uppercase_close[64], uppercase_cancel[64]; | ||||||
| 
 | 
 | ||||||
| extern BOOL enable_iso, enable_joliet, enable_rockridge, enable_ntfs_compression; | extern BOOL enable_iso, enable_joliet, enable_rockridge, enable_ntfs_compression; | ||||||
| extern uint8_t* grub2_buf; | extern uint8_t* grub2_buf; | ||||||
|  | @ -102,13 +103,14 @@ char szFolderPath[MAX_PATH], app_dir[MAX_PATH], system_dir[MAX_PATH], temp_dir[M | ||||||
| char *image_path = NULL, *short_image_path; | char *image_path = NULL, *short_image_path; | ||||||
| float fScale = 1.0f; | float fScale = 1.0f; | ||||||
| int default_fs, fs, bt, pt, tt; | int default_fs, fs, bt, pt, tt; | ||||||
|  | int cbw, ddw; // (empty) check box width, (empty) drop down width
 | ||||||
| uint32_t dur_mins, dur_secs; | uint32_t dur_mins, dur_secs; | ||||||
| loc_cmd* selected_locale = NULL; | loc_cmd* selected_locale = NULL; | ||||||
| WORD selected_langid = MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT); | WORD selected_langid = MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT); | ||||||
| DWORD MainThreadId; | DWORD MainThreadId; | ||||||
| HWND hDeviceList, hPartitionScheme, hTargetSystem, hFileSystem, hClusterSize, hLabel, hBootType, hNBPasses, hLog = NULL; | HWND hDeviceList, hPartitionScheme, hTargetSystem, hFileSystem, hClusterSize, hLabel, hBootType, hNBPasses, hLog = NULL; | ||||||
| HWND hLogDlg = NULL, hProgress = NULL, hDiskID; | HWND hLogDlg = NULL, hProgress = NULL, hDiskID; | ||||||
| BOOL use_own_c32[NB_OLD_C32] = {FALSE, FALSE}, mbr_selected_by_user = FALSE, togo_mode = FALSE; | BOOL use_own_c32[NB_OLD_C32] = {FALSE, FALSE}, mbr_selected_by_user = FALSE, display_togo_option = FALSE; | ||||||
| BOOL iso_op_in_progress = FALSE, format_op_in_progress = FALSE, right_to_left_mode = FALSE, progress_in_use = FALSE, has_uefi_csm; | BOOL iso_op_in_progress = FALSE, format_op_in_progress = FALSE, right_to_left_mode = FALSE, progress_in_use = FALSE, has_uefi_csm; | ||||||
| BOOL enable_HDDs = FALSE, force_update = FALSE, enable_ntfs_compression = FALSE, no_confirmation_on_cancel = FALSE, lock_drive = TRUE; | BOOL enable_HDDs = FALSE, force_update = FALSE, enable_ntfs_compression = FALSE, no_confirmation_on_cancel = FALSE, lock_drive = TRUE; | ||||||
| BOOL advanced_mode_device, advanced_mode_format, allow_dual_uefi_bios, detect_fakes, enable_vmdk, force_large_fat32, usb_debug, use_fake_units, preserve_timestamps; | BOOL advanced_mode_device, advanced_mode_format, allow_dual_uefi_bios, detect_fakes, enable_vmdk, force_large_fat32, usb_debug, use_fake_units, preserve_timestamps; | ||||||
|  | @ -252,15 +254,15 @@ static void SetPartitionSchemeAndTargetSystem(BOOL only_target) | ||||||
| 	BOOL allowed_partition_scheme[3] = { TRUE, TRUE, FALSE }; | 	BOOL allowed_partition_scheme[3] = { TRUE, TRUE, FALSE }; | ||||||
| 	//                                   BIOS, UEFI, DUAL
 | 	//                                   BIOS, UEFI, DUAL
 | ||||||
| 	BOOL allowed_target_system[3]    = { TRUE, TRUE, FALSE }; | 	BOOL allowed_target_system[3]    = { TRUE, TRUE, FALSE }; | ||||||
| 	BOOL dual_boot = FALSE; | 	BOOL is_windows_to_go_selected; | ||||||
| 	// TODO: Windows To Go selected
 |  | ||||||
| 	BOOL is_windows_to_go_selected = FALSE; |  | ||||||
| 
 | 
 | ||||||
| 	if (!only_target) | 	if (!only_target) | ||||||
| 		IGNORE_RETVAL(ComboBox_ResetContent(hPartitionScheme)); | 		IGNORE_RETVAL(ComboBox_ResetContent(hPartitionScheme)); | ||||||
| 	IGNORE_RETVAL(ComboBox_ResetContent(hTargetSystem)); | 	IGNORE_RETVAL(ComboBox_ResetContent(hTargetSystem)); | ||||||
| 
 | 
 | ||||||
| 	bt = (int)ComboBox_GetItemData(hBootType, ComboBox_GetCurSel(hBootType)); | 	bt = (int)ComboBox_GetItemData(hBootType, ComboBox_GetCurSel(hBootType)); | ||||||
|  | 	is_windows_to_go_selected = (bt == BT_IMAGE) && (image_path != NULL) && HAS_WINTOGO(img_report) && | ||||||
|  | 		(ComboBox_GetCurSel(GetDlgItem(hMainDialog, IDC_IMAGE_OPTION)) == 1); | ||||||
| 	// If no device is selected, don't populate anything
 | 	// If no device is selected, don't populate anything
 | ||||||
| 	if (ComboBox_GetCurSel(hDeviceList) < 0) | 	if (ComboBox_GetCurSel(hDeviceList) < 0) | ||||||
| 		return; | 		return; | ||||||
|  | @ -557,8 +559,8 @@ static void SetFSFromISO(void) | ||||||
| { | { | ||||||
| 	int i, fs_tmp, selected_fs = FS_UNKNOWN; | 	int i, fs_tmp, selected_fs = FS_UNKNOWN; | ||||||
| 	uint32_t fs_mask = 0; | 	uint32_t fs_mask = 0; | ||||||
| 	BOOL windows_to_go = (togo_mode) && HAS_WINTOGO(img_report) && | 	BOOL windows_to_go = display_togo_option && (bt == BT_IMAGE) && HAS_WINTOGO(img_report) && | ||||||
| 		(Button_GetCheck(GetDlgItem(hMainDialog, IDC_WINDOWS_TO_GO)) == BST_CHECKED); | 		(ComboBox_GetCurSel(GetDlgItem(hMainDialog, IDC_IMAGE_OPTION)) == 1); | ||||||
| 
 | 
 | ||||||
| 	if (image_path == NULL) | 	if (image_path == NULL) | ||||||
| 		return; | 		return; | ||||||
|  | @ -604,7 +606,7 @@ static void SetMBRProps(void) | ||||||
| 	BOOL needs_masquerading = HAS_WINPE(img_report) && (!img_report.uses_minint); | 	BOOL needs_masquerading = HAS_WINPE(img_report) && (!img_report.uses_minint); | ||||||
| 
 | 
 | ||||||
| 	if ((!mbr_selected_by_user) && ((image_path == NULL) || (bt != BT_IMAGE) || (fs != FS_NTFS) || HAS_GRUB(img_report) || | 	if ((!mbr_selected_by_user) && ((image_path == NULL) || (bt != BT_IMAGE) || (fs != FS_NTFS) || HAS_GRUB(img_report) || | ||||||
| 		((togo_mode) && (Button_GetCheck(GetDlgItem(hMainDialog, IDC_WINDOWS_TO_GO)) == BST_CHECKED)) )) { | 		((display_togo_option) && (ComboBox_GetCurSel(GetDlgItem(hMainDialog, IDC_IMAGE_OPTION)) == 1)) )) { | ||||||
| 		CheckDlgButton(hMainDialog, IDC_RUFUS_MBR, BST_UNCHECKED); | 		CheckDlgButton(hMainDialog, IDC_RUFUS_MBR, BST_UNCHECKED); | ||||||
| 		IGNORE_RETVAL(ComboBox_SetCurSel(hDiskID, 0)); | 		IGNORE_RETVAL(ComboBox_SetCurSel(hDiskID, 0)); | ||||||
| 		return; | 		return; | ||||||
|  | @ -618,7 +620,7 @@ static void SetMBRProps(void) | ||||||
| 
 | 
 | ||||||
| static void SetToGo(void) | static void SetToGo(void) | ||||||
| { | { | ||||||
| 	if (((bt != BT_IMAGE) && (togo_mode)) || ((bt == BT_IMAGE) && (HAS_WINTOGO(img_report)) && (!togo_mode))) { | 	if (((bt != BT_IMAGE) && (display_togo_option)) || ((bt == BT_IMAGE) && (HAS_WINTOGO(img_report)) && (!display_togo_option))) { | ||||||
| 		ToggleImageOption(); | 		ToggleImageOption(); | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|  | @ -750,7 +752,7 @@ static void EnableControls(BOOL bEnable) | ||||||
| 	EnableWindow(GetDlgItem(hMainDialog, IDC_HASH), bEnable && (bt == BT_IMAGE) && (image_path != NULL)); | 	EnableWindow(GetDlgItem(hMainDialog, IDC_HASH), bEnable && (bt == BT_IMAGE) && (image_path != NULL)); | ||||||
| 
 | 
 | ||||||
| 	// Toggle CLOSE/CANCEL
 | 	// Toggle CLOSE/CANCEL
 | ||||||
| 	SetDlgItemTextU(hMainDialog, IDCANCEL, lmprintf(bEnable ? MSG_006 : MSG_007)); | 	SetDlgItemTextU(hMainDialog, IDCANCEL, bEnable ? uppercase_close : uppercase_cancel); | ||||||
| 
 | 
 | ||||||
| 	// Only enable the following controls if a device is active
 | 	// Only enable the following controls if a device is active
 | ||||||
| 	bEnable = (ComboBox_GetCurSel(hDeviceList) < 0) ? FALSE : bEnable; | 	bEnable = (ComboBox_GetCurSel(hDeviceList) < 0) ? FALSE : bEnable; | ||||||
|  | @ -1097,7 +1099,7 @@ static void DisplayISOProps(void) | ||||||
| 
 | 
 | ||||||
| 	// We don't support ToGo on Windows 7 or earlier, for lack of native ISO mounting capabilities
 | 	// We don't support ToGo on Windows 7 or earlier, for lack of native ISO mounting capabilities
 | ||||||
| 	if (nWindowsVersion >= WINDOWS_8) | 	if (nWindowsVersion >= WINDOWS_8) | ||||||
| 		if ( ((!togo_mode) && (HAS_WINTOGO(img_report))) || ((togo_mode) && (!HAS_WINTOGO(img_report))) ) | 		if ( ((!display_togo_option) && (HAS_WINTOGO(img_report))) || ((display_togo_option) && (!HAS_WINTOGO(img_report))) ) | ||||||
| 			ToggleImageOption(); | 			ToggleImageOption(); | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | @ -1154,7 +1156,7 @@ static void ToggleAdvancedDeviceOptions(BOOL enable) | ||||||
| 	status_vpos += shift; | 	status_vpos += shift; | ||||||
| 
 | 
 | ||||||
| 	// Toggle the Hide/Show toolbar text
 | 	// Toggle the Hide/Show toolbar text
 | ||||||
| 	utf8_to_wchar_no_alloc(lmprintf((enable) ? MSG_311 : MSG_310, lmprintf(MSG_308)), wtbtext[0], ARRAYSIZE(wtbtext[0])); | 	utf8_to_wchar_no_alloc(lmprintf((enable) ? MSG_122 : MSG_121, lmprintf(MSG_119)), wtbtext[0], ARRAYSIZE(wtbtext[0])); | ||||||
| 	button_info.cbSize = sizeof(button_info); | 	button_info.cbSize = sizeof(button_info); | ||||||
| 	button_info.dwMask = TBIF_TEXT; | 	button_info.dwMask = TBIF_TEXT; | ||||||
| 	button_info.pszText = wtbtext[0]; | 	button_info.pszText = wtbtext[0]; | ||||||
|  | @ -1197,7 +1199,7 @@ static void ToggleAdvancedFormatOptions(BOOL enable) | ||||||
| 	status_vpos += shift; | 	status_vpos += shift; | ||||||
| 
 | 
 | ||||||
| 	// Toggle the Hide/Show toolbar text
 | 	// Toggle the Hide/Show toolbar text
 | ||||||
| 	utf8_to_wchar_no_alloc(lmprintf((enable) ? MSG_311 : MSG_310, lmprintf(MSG_309)), wtbtext[1], ARRAYSIZE(wtbtext[0])); | 	utf8_to_wchar_no_alloc(lmprintf((enable) ? MSG_122 : MSG_121, lmprintf(MSG_120)), wtbtext[1], ARRAYSIZE(wtbtext[0])); | ||||||
| 	button_info.cbSize = sizeof(button_info); | 	button_info.cbSize = sizeof(button_info); | ||||||
| 	button_info.dwMask = TBIF_TEXT; | 	button_info.dwMask = TBIF_TEXT; | ||||||
| 	button_info.pszText = wtbtext[1]; | 	button_info.pszText = wtbtext[1]; | ||||||
|  | @ -1231,16 +1233,16 @@ static void ToggleImageOption(void) | ||||||
| 	// Windows To Go mode is only available for Windows 8 or later due to the lack
 | 	// Windows To Go mode is only available for Windows 8 or later due to the lack
 | ||||||
| 	// of an ISO mounting API on previous versions.
 | 	// of an ISO mounting API on previous versions.
 | ||||||
| 	// But we still need to be able to hide the Windows To Go option on startup.
 | 	// But we still need to be able to hide the Windows To Go option on startup.
 | ||||||
| 	if ((nWindowsVersion < WINDOWS_8) && (!togo_mode)) | 	if ((nWindowsVersion < WINDOWS_8) && (!display_togo_option)) | ||||||
| 		return; | 		return; | ||||||
| 
 | 
 | ||||||
| 	togo_mode = !togo_mode; | 	display_togo_option = !display_togo_option; | ||||||
| 	if (togo_mode) { | 	if (display_togo_option) { | ||||||
| 		hCtrl = GetDlgItem(hMainDialog, IDC_IMAGE_OPTION); | 		hCtrl = GetDlgItem(hMainDialog, IDC_IMAGE_OPTION); | ||||||
| 		// Populate the dropdown
 | 		// Populate the dropdown
 | ||||||
| 		IGNORE_RETVAL(ComboBox_ResetContent(hCtrl)); | 		IGNORE_RETVAL(ComboBox_ResetContent(hCtrl)); | ||||||
| 		IGNORE_RETVAL(ComboBox_SetItemData(hCtrl, ComboBox_AddStringU(hCtrl, lmprintf(MSG_301)), FALSE)); | 		IGNORE_RETVAL(ComboBox_SetItemData(hCtrl, ComboBox_AddStringU(hCtrl, lmprintf(MSG_117)), FALSE)); | ||||||
| 		IGNORE_RETVAL(ComboBox_SetItemData(hCtrl, ComboBox_AddStringU(hCtrl, lmprintf(MSG_302)), TRUE)); | 		IGNORE_RETVAL(ComboBox_SetItemData(hCtrl, ComboBox_AddStringU(hCtrl, lmprintf(MSG_118)), TRUE)); | ||||||
| 		IGNORE_RETVAL(ComboBox_SetCurSel(hCtrl, 0)); | 		IGNORE_RETVAL(ComboBox_SetCurSel(hCtrl, 0)); | ||||||
| 	} else | 	} else | ||||||
| 		shift = -shift; | 		shift = -shift; | ||||||
|  | @ -1256,7 +1258,7 @@ static void ToggleImageOption(void) | ||||||
| 
 | 
 | ||||||
| 	// Hide or show the boot options
 | 	// Hide or show the boot options
 | ||||||
| 	for (i = 0; i < ARRAYSIZE(image_option_toggle_ids); i++) | 	for (i = 0; i < ARRAYSIZE(image_option_toggle_ids); i++) | ||||||
| 		ShowWindow(GetDlgItem(hMainDialog, image_option_toggle_ids[i]), togo_mode ? SW_SHOW : SW_HIDE); | 		ShowWindow(GetDlgItem(hMainDialog, image_option_toggle_ids[i]), display_togo_option ? SW_SHOW : SW_HIDE); | ||||||
| 
 | 
 | ||||||
| 	// If you don't force a redraw here, all kind of bad UI artifacts happen...
 | 	// If you don't force a redraw here, all kind of bad UI artifacts happen...
 | ||||||
| 	InvalidateRect(hMainDialog, NULL, TRUE); | 	InvalidateRect(hMainDialog, NULL, TRUE); | ||||||
|  | @ -1422,7 +1424,7 @@ static BOOL BootCheck(void) | ||||||
| 			// Pure DD images are fine at this stage
 | 			// Pure DD images are fine at this stage
 | ||||||
| 			return TRUE; | 			return TRUE; | ||||||
| 		} | 		} | ||||||
| 		if ((togo_mode) && (Button_GetCheck(GetDlgItem(hMainDialog, IDC_WINDOWS_TO_GO)) == BST_CHECKED)) { | 		if ((display_togo_option) && (ComboBox_GetCurSel(GetDlgItem(hMainDialog, IDC_IMAGE_OPTION)) == 1)) { | ||||||
| 			if (fs != FS_NTFS) { | 			if (fs != FS_NTFS) { | ||||||
| 				// Windows To Go only works for NTFS
 | 				// Windows To Go only works for NTFS
 | ||||||
| 				MessageBoxExU(hMainDialog, lmprintf(MSG_097, "Windows To Go"), lmprintf(MSG_092), MB_OK|MB_ICONERROR|MB_IS_RTL, selected_langid); | 				MessageBoxExU(hMainDialog, lmprintf(MSG_097, "Windows To Go"), lmprintf(MSG_092), MB_OK|MB_ICONERROR|MB_IS_RTL, selected_langid); | ||||||
|  | @ -1818,7 +1820,7 @@ static void CreateAdditionalControls(HWND hDlg) | ||||||
| 
 | 
 | ||||||
| 	// Create the advanced options toolbars
 | 	// Create the advanced options toolbars
 | ||||||
| 	memset(wtbtext, 0, sizeof(wtbtext)); | 	memset(wtbtext, 0, sizeof(wtbtext)); | ||||||
| 	utf8_to_wchar_no_alloc(lmprintf((advanced_mode_device) ? MSG_311 : MSG_310, lmprintf(MSG_308)), wtbtext[0], ARRAYSIZE(wtbtext[0])); | 	utf8_to_wchar_no_alloc(lmprintf((advanced_mode_device) ? MSG_122 : MSG_121, lmprintf(MSG_119)), wtbtext[0], ARRAYSIZE(wtbtext[0])); | ||||||
| 	hAdvancedDeviceToolbar = CreateWindowExW(0, TOOLBARCLASSNAME, NULL, | 	hAdvancedDeviceToolbar = CreateWindowExW(0, TOOLBARCLASSNAME, NULL, | ||||||
| 		WS_CHILD | WS_TABSTOP | WS_VISIBLE | WS_CLIPSIBLINGS | WS_CLIPCHILDREN | CCS_NOPARENTALIGN | | 		WS_CHILD | WS_TABSTOP | WS_VISIBLE | WS_CLIPSIBLINGS | WS_CLIPCHILDREN | CCS_NOPARENTALIGN | | ||||||
| 		CCS_NODIVIDER | TBSTYLE_FLAT | TBSTYLE_LIST | TBSTYLE_TRANSPARENT | TBSTYLE_TOOLTIPS | TBSTYLE_AUTOSIZE, | 		CCS_NODIVIDER | TBSTYLE_FLAT | TBSTYLE_LIST | TBSTYLE_TRANSPARENT | TBSTYLE_TOOLTIPS | TBSTYLE_AUTOSIZE, | ||||||
|  | @ -1838,7 +1840,7 @@ static void CreateAdditionalControls(HWND hDlg) | ||||||
| 	SendMessage(hAdvancedDeviceToolbar, TB_GETIDEALSIZE, (WPARAM)FALSE, (LPARAM)&sz); | 	SendMessage(hAdvancedDeviceToolbar, TB_GETIDEALSIZE, (WPARAM)FALSE, (LPARAM)&sz); | ||||||
| 	SetWindowPos(hAdvancedDeviceToolbar, HWND_TOP, rc.left + toolbar_fudge, rc.top, sz.cx, rc.bottom - rc.top, 0); | 	SetWindowPos(hAdvancedDeviceToolbar, HWND_TOP, rc.left + toolbar_fudge, rc.top, sz.cx, rc.bottom - rc.top, 0); | ||||||
| 
 | 
 | ||||||
| 	utf8_to_wchar_no_alloc(lmprintf((advanced_mode_format) ? MSG_311 : MSG_310, lmprintf(MSG_309)), wtbtext[1], ARRAYSIZE(wtbtext[1])); | 	utf8_to_wchar_no_alloc(lmprintf((advanced_mode_format) ? MSG_122 : MSG_121, lmprintf(MSG_120)), wtbtext[1], ARRAYSIZE(wtbtext[1])); | ||||||
| 	hAdvancedFormatToolbar = CreateWindowExW(0, TOOLBARCLASSNAME, NULL, | 	hAdvancedFormatToolbar = CreateWindowExW(0, TOOLBARCLASSNAME, NULL, | ||||||
| 		WS_CHILD | WS_TABSTOP | WS_VISIBLE | WS_CLIPSIBLINGS | WS_CLIPCHILDREN  | CCS_NOPARENTALIGN | | 		WS_CHILD | WS_TABSTOP | WS_VISIBLE | WS_CLIPSIBLINGS | WS_CLIPCHILDREN  | CCS_NOPARENTALIGN | | ||||||
| 		CCS_NODIVIDER | TBSTYLE_FLAT | TBSTYLE_LIST | TBSTYLE_TRANSPARENT | TBSTYLE_TOOLTIPS | TBSTYLE_AUTOSIZE, | 		CCS_NODIVIDER | TBSTYLE_FLAT | TBSTYLE_LIST | TBSTYLE_TRANSPARENT | TBSTYLE_TOOLTIPS | TBSTYLE_AUTOSIZE, | ||||||
|  | @ -1944,8 +1946,8 @@ static void GetBasicControlsWidth(HWND hDlg) | ||||||
| 	} | 	} | ||||||
| 
 | 
 | ||||||
| 	// Checkbox and (blank) dropdown widths
 | 	// Checkbox and (blank) dropdown widths
 | ||||||
| 	cb_width = MulDiv(checkbox_internal_spacing, bu.cx, 4); | 	cbw = MulDiv(checkbox_internal_spacing, bu.cx, 4); | ||||||
| 	dd_width = MulDiv(dropdown_internal_spacing, bu.cx, 4); | 	ddw = MulDiv(dropdown_internal_spacing, bu.cx, 4); | ||||||
| 
 | 
 | ||||||
| 	// Spacing width between half-length dropdowns (sep) as well as left margin
 | 	// Spacing width between half-length dropdowns (sep) as well as left margin
 | ||||||
| 	GetWindowRect(GetDlgItem(hDlg, IDC_TARGET_SYSTEM), &rc); | 	GetWindowRect(GetDlgItem(hDlg, IDC_TARGET_SYSTEM), &rc); | ||||||
|  | @ -1980,13 +1982,11 @@ static void GetMainButtonsWidth(HWND hDlg) | ||||||
| 	GetWindowRect(GetDlgItem(hDlg, main_button_ids[0]), &rc); | 	GetWindowRect(GetDlgItem(hDlg, main_button_ids[0]), &rc); | ||||||
| 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | ||||||
| 	bw = rc.right - rc.left; | 	bw = rc.right - rc.left; | ||||||
| uprintf("initial bw = %d", bw); |  | ||||||
| 
 | 
 | ||||||
| 	for (i = 0; i < ARRAYSIZE(main_button_ids); i++) | 	for (i = 0; i < ARRAYSIZE(main_button_ids); i++) | ||||||
| 		bw = max(GetTextWidth(hDlg, main_button_ids[i]) + cb_width, bw); | 		bw = max(bw, GetTextWidth(hDlg, main_button_ids[i]) + cbw); | ||||||
| 	// The 'CLOSE' button is also be used to display 'CANCEL' => measure that too
 | 	// The 'CLOSE' button is also be used to display 'CANCEL' => measure that too
 | ||||||
| 	bw = max(bw, GetTextSize(GetDlgItem(hDlg, IDCANCEL), lmprintf(MSG_007)).cx + cb_width); | 	bw = max(bw, GetTextSize(GetDlgItem(hDlg, IDCANCEL), lmprintf(MSG_007)).cx + cbw); | ||||||
| uprintf("adjusted bw = %d", bw); |  | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| // The following goes over the data that gets populated into the half-width dropdowns
 | // The following goes over the data that gets populated into the half-width dropdowns
 | ||||||
|  | @ -1999,11 +1999,9 @@ static void GetHalfDropwdownWidth(HWND hDlg) | ||||||
| 	char tmp[256]; | 	char tmp[256]; | ||||||
| 
 | 
 | ||||||
| 	// Initialize half width to the UI's default size
 | 	// Initialize half width to the UI's default size
 | ||||||
| 	// TODO: verify that this works if we just resized from a language with larger width?
 |  | ||||||
| 	GetWindowRect(GetDlgItem(hDlg, IDC_PARTITION_TYPE), &rc); | 	GetWindowRect(GetDlgItem(hDlg, IDC_PARTITION_TYPE), &rc); | ||||||
| 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | ||||||
| uprintf("initial hw = %d", rc.right - rc.left); | 	hw = rc.right - rc.left - ddw; | ||||||
| 	hw = rc.right - rc.left - dd_width; |  | ||||||
| 
 | 
 | ||||||
| 	// "Super Floppy Disk" is the longuest entry in the Partition Scheme dropdown
 | 	// "Super Floppy Disk" is the longuest entry in the Partition Scheme dropdown
 | ||||||
| 	hw = max(hw, GetTextSize(GetDlgItem(hDlg, IDC_PARTITION_TYPE), (char*)sfd_name).cx); | 	hw = max(hw, GetTextSize(GetDlgItem(hDlg, IDC_PARTITION_TYPE), (char*)sfd_name).cx); | ||||||
|  | @ -2033,8 +2031,7 @@ uprintf("initial hw = %d", rc.right - rc.left); | ||||||
| 	hw = max(hw, GetTextWidth(hDlg, IDC_BADBLOCKS) - sw); | 	hw = max(hw, GetTextWidth(hDlg, IDC_BADBLOCKS) - sw); | ||||||
| 
 | 
 | ||||||
| 	// Add the width of a blank dropdown
 | 	// Add the width of a blank dropdown
 | ||||||
| 	hw += dd_width; | 	hw += ddw; | ||||||
| uprintf("adjusted hw = %d, 2*bw + ssw = %d", hw, 2 * bw + ssw); |  | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| /*
 | /*
 | ||||||
|  | @ -2057,38 +2054,33 @@ uprintf("adjusted hw = %d, 2*bw + ssw = %d", hw, 2 * bw + ssw); | ||||||
| static void GetFullWidth(HWND hDlg) | static void GetFullWidth(HWND hDlg) | ||||||
| { | { | ||||||
| 	RECT rc; | 	RECT rc; | ||||||
| 	int i, control[] = { IDC_LIST_USB_HDD, IDC_OLD_BIOS_FIXES, IDC_QUICKFORMAT, IDC_EXTENDED_LABEL }; | 	int i; | ||||||
| 
 | 
 | ||||||
| 	// Compute the minimum size needed for the Boot Selection dropdown
 | 	// Compute the minimum size needed for the Boot Selection dropdown
 | ||||||
| 	GetWindowRect(GetDlgItem(hDlg, IDC_BOOT_TYPE), &rc); | 	GetWindowRect(GetDlgItem(hDlg, IDC_BOOT_TYPE), &rc); | ||||||
| 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | ||||||
| uprintf("initial bsw = %d", rc.right - rc.left); | 
 | ||||||
| 	bsw = max(rc.right - rc.left, GetTextSize(hBootType, lmprintf(MSG_281, lmprintf(MSG_280))).cx + dd_width); | 	bsw = max(rc.right - rc.left, GetTextSize(hBootType, lmprintf(MSG_279)).cx + ddw); | ||||||
| uprintf("updated bsw = %d", bsw); | 	bsw = max(bsw, GetTextSize(hBootType, lmprintf(MSG_281, lmprintf(MSG_280))).cx + ddw); | ||||||
| uprintf("ssw = %d, sbw = %d", ssw, sbw); |  | ||||||
| 
 | 
 | ||||||
| 	// Initialize full width to the UI's default size
 | 	// Initialize full width to the UI's default size
 | ||||||
| 	GetWindowRect(GetDlgItem(hDlg, IDC_IMAGE_OPTION), &rc); | 	GetWindowRect(GetDlgItem(hDlg, IDC_IMAGE_OPTION), &rc); | ||||||
| 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | ||||||
| uprintf("initial fw = %d", rc.right - rc.left); | 	fw = rc.right - rc.left - ddw; | ||||||
| 	fw = rc.right - rc.left - dd_width; |  | ||||||
| 
 | 
 | ||||||
| 	// Go through the Image Options for Windows To Go
 | 	// Go through the Image Options for Windows To Go
 | ||||||
| 	fw = max(fw, GetTextSize(GetDlgItem(hDlg, IDC_IMAGE_OPTION), lmprintf(MSG_301)).cx); | 	fw = max(fw, GetTextSize(GetDlgItem(hDlg, IDC_IMAGE_OPTION), lmprintf(MSG_117)).cx); | ||||||
| 	fw = max(fw, GetTextSize(GetDlgItem(hDlg, IDC_IMAGE_OPTION), lmprintf(MSG_302)).cx); | 	fw = max(fw, GetTextSize(GetDlgItem(hDlg, IDC_IMAGE_OPTION), lmprintf(MSG_118)).cx); | ||||||
| 
 | 
 | ||||||
| 	// Now deal with full length checkbox lines
 | 	// Now deal with full length checkbox lines
 | ||||||
| 	for (i=0; i<ARRAYSIZE(control); i++) | 	for (i=0; i<ARRAYSIZE(full_width_checkboxes); i++) | ||||||
| 		fw = max(fw, GetTextWidth(hDlg, control[i])); | 		fw = max(fw, GetTextWidth(hDlg, full_width_checkboxes[i])); | ||||||
| 
 | 
 | ||||||
| 	// All of the above is for text only, so we need to add dd space
 | 	// All of the above is for text only, so we need to add dd space
 | ||||||
| 	fw += dd_width; | 	fw += ddw; | ||||||
| 
 | 
 | ||||||
| 	// Our min also needs to be longer than 2 half length dropdowns + spacer
 | 	// Our min also needs to be longer than 2 half length dropdowns + spacer
 | ||||||
| 	fw = max(fw, 2 * hw + sw); | 	fw = max(fw, 2 * hw + sw); | ||||||
| uprintf("adjusted fw = %d", fw); |  | ||||||
| uprintf("bsw + 2*ssw + hbw + bw = %d", bsw + 2*ssw + hbw + bw); |  | ||||||
| 
 |  | ||||||
| 
 | 
 | ||||||
| 	// Now that we have our minimum full width, adjust the button width if needed
 | 	// Now that we have our minimum full width, adjust the button width if needed
 | ||||||
| 	// Adjust according to min full width
 | 	// Adjust according to min full width
 | ||||||
|  | @ -2096,9 +2088,6 @@ uprintf("bsw + 2*ssw + hbw + bw = %d", bsw + 2*ssw + hbw + bw); | ||||||
| 	// Adjust according to min boot selection width
 | 	// Adjust according to min boot selection width
 | ||||||
| 	bw = max(bw, (bsw + hbw - sw) / 3); | 	bw = max(bw, (bsw + hbw - sw) / 3); | ||||||
| 
 | 
 | ||||||
| 	uprintf("fw = %d, 4bw + 2ssw + sw = %d", fw, 4 * bw + 2 * ssw + sw); |  | ||||||
| 	uprintf("bsw + 2ssw + hbw + bw = %d", bsw + 2 * ssw + hbw + bw); |  | ||||||
| 
 |  | ||||||
| 	// Adjust according to min half width
 | 	// Adjust according to min half width
 | ||||||
| 	bw = max(bw, (hw / 2) - ssw); | 	bw = max(bw, (hw / 2) - ssw); | ||||||
| 
 | 
 | ||||||
|  | @ -2148,7 +2137,6 @@ static void PositionControls(HWND hDlg) | ||||||
| 
 | 
 | ||||||
| 	// Start by resizing the whole dialog
 | 	// Start by resizing the whole dialog
 | ||||||
| 	GetWindowRect(hDlg, &rc); | 	GetWindowRect(hDlg, &rc); | ||||||
| 	uprintf("initial dialog width = %d (mw = %d)", rc.right - rc.left, mw); |  | ||||||
| 	// Don't ask me why we need 3 times the margin width here instead of 2...
 | 	// Don't ask me why we need 3 times the margin width here instead of 2...
 | ||||||
| 	// TODO: If that doesn't work, just pick additonal space from initial fw and reuse that
 | 	// TODO: If that doesn't work, just pick additonal space from initial fw and reuse that
 | ||||||
| 	SetWindowPos(hDlg, NULL, -1, -1, 3*mw + fw, rc.bottom - rc.top, SWP_NOMOVE | SWP_NOZORDER); | 	SetWindowPos(hDlg, NULL, -1, -1, 3*mw + fw, rc.bottom - rc.top, SWP_NOMOVE | SWP_NOZORDER); | ||||||
|  | @ -2243,6 +2231,13 @@ static void PositionControls(HWND hDlg) | ||||||
| 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | ||||||
| 	SetWindowPos(hCtrl, HWND_TOP, mw + fw - sbw, rc.top, sbw, rc.bottom - rc.top, 0); | 	SetWindowPos(hCtrl, HWND_TOP, mw + fw - sbw, rc.top, sbw, rc.bottom - rc.top, 0); | ||||||
| 
 | 
 | ||||||
|  | 	// Reposition the CSM help tip
 | ||||||
|  | 	hCtrl = GetDlgItem(hDlg, IDS_CSM_HELP_TXT); | ||||||
|  | 	GetWindowRect(hCtrl, &rc); | ||||||
|  | 	MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | ||||||
|  | 	// TODO: measure space and avoid button fudging
 | ||||||
|  | 	SetWindowPos(hCtrl, HWND_TOP, mw + fw + 5 * button_fudge / 2, rc.top, sbw, rc.bottom - rc.top, 0); | ||||||
|  | 
 | ||||||
| 	if (advanced_mode_device) { | 	if (advanced_mode_device) { | ||||||
| 		// Still need to adjust the width of the device selection dropdown
 | 		// Still need to adjust the width of the device selection dropdown
 | ||||||
| 		GetWindowRect(hDeviceList, &rc); | 		GetWindowRect(hDeviceList, &rc); | ||||||
|  | @ -2340,6 +2335,22 @@ static void InitDialog(HWND hDlg) | ||||||
| 	hDiskID = GetDlgItem(hDlg, IDC_DISK_ID); | 	hDiskID = GetDlgItem(hDlg, IDC_DISK_ID); | ||||||
| 	hStart = GetDlgItem(hDlg, IDC_START); | 	hStart = GetDlgItem(hDlg, IDC_START); | ||||||
| 
 | 
 | ||||||
|  | 	// Convert the main button labels to uppercase
 | ||||||
|  | 	GetWindowTextU(hStart, uppercase_start, sizeof(uppercase_start)); | ||||||
|  | 	CharUpperBuffU(uppercase_start, sizeof(uppercase_start)); | ||||||
|  | 	SetWindowTextU(hStart, uppercase_start); | ||||||
|  | 	GetWindowTextU(GetDlgItem(hDlg, IDCANCEL), uppercase_close, sizeof(uppercase_close)); | ||||||
|  | 	CharUpperBuffU(uppercase_close, sizeof(uppercase_close)); | ||||||
|  | 	// Hardcoded exception for German
 | ||||||
|  | 	if (strcmp("SCHLIEßEN", uppercase_close) == 0) | ||||||
|  | 		strcpy(uppercase_close, "SCHLIESSEN"); | ||||||
|  | 	SetWindowTextU(GetDlgItem(hDlg, IDCANCEL), uppercase_close); | ||||||
|  | 	GetWindowTextU(GetDlgItem(hDlg, IDC_SELECT), uppercase_select, sizeof(uppercase_select)); | ||||||
|  | 	CharUpperBuffU(uppercase_select, sizeof(uppercase_select)); | ||||||
|  | 	SetWindowTextU(GetDlgItem(hDlg, IDC_SELECT), uppercase_select); | ||||||
|  | 	strcpy(uppercase_cancel, lmprintf(MSG_007)); | ||||||
|  | 	CharUpperBuffU(uppercase_cancel, sizeof(uppercase_cancel)); | ||||||
|  | 
 | ||||||
| 	GetBasicControlsWidth(hDlg); | 	GetBasicControlsWidth(hDlg); | ||||||
| 	GetMainButtonsWidth(hDlg); | 	GetMainButtonsWidth(hDlg); | ||||||
| 	GetHalfDropwdownWidth(hDlg); | 	GetHalfDropwdownWidth(hDlg); | ||||||
|  | @ -2458,7 +2469,7 @@ static void InitDialog(HWND hDlg) | ||||||
| 	CreateTooltip(hTargetSystem, lmprintf(MSG_151), 30000); | 	CreateTooltip(hTargetSystem, lmprintf(MSG_151), 30000); | ||||||
| 	CreateTooltip(GetDlgItem(hDlg, IDS_CSM_HELP_TXT), lmprintf(MSG_152), 30000); | 	CreateTooltip(GetDlgItem(hDlg, IDS_CSM_HELP_TXT), lmprintf(MSG_152), 30000); | ||||||
| 	CreateTooltip(GetDlgItem(hDlg, IDC_HASH), lmprintf(MSG_272), -1); | 	CreateTooltip(GetDlgItem(hDlg, IDC_HASH), lmprintf(MSG_272), -1); | ||||||
| 	CreateTooltip(GetDlgItem(hDlg, IDC_SAVE), lmprintf(MSG_312), -1); | 	CreateTooltip(GetDlgItem(hDlg, IDC_SAVE), lmprintf(MSG_304), -1); | ||||||
| 
 | 
 | ||||||
| 	if (!advanced_mode_device)	// Hide as needed, since we display the advanced controls by default
 | 	if (!advanced_mode_device)	// Hide as needed, since we display the advanced controls by default
 | ||||||
| 		ToggleAdvancedDeviceOptions(FALSE); | 		ToggleAdvancedDeviceOptions(FALSE); | ||||||
|  | @ -2973,15 +2984,6 @@ static INT_PTR CALLBACK MainCallback(HWND hDlg, UINT message, WPARAM wParam, LPA | ||||||
| 				FormatStatus = ERROR_SEVERITY_ERROR|FAC(FACILITY_STORAGE)|APPERR(ERROR_CANT_START_THREAD); | 				FormatStatus = ERROR_SEVERITY_ERROR|FAC(FACILITY_STORAGE)|APPERR(ERROR_CANT_START_THREAD); | ||||||
| 			} | 			} | ||||||
| 			break; | 			break; | ||||||
| 		case IDC_WINDOWS_INSTALL: |  | ||||||
| 		case IDC_WINDOWS_TO_GO: |  | ||||||
| 			if ( (Button_GetCheck(GetDlgItem(hMainDialog, IDC_WINDOWS_INSTALL)) == BST_CHECKED) || |  | ||||||
| 				 (Button_GetCheck(GetDlgItem(hMainDialog, IDC_WINDOWS_TO_GO)) == BST_CHECKED) ) { |  | ||||||
| //				SetFSFromISO();
 |  | ||||||
| //				SetMBRProps();
 |  | ||||||
| //				SetMBRForUEFI(TRUE);
 |  | ||||||
| 			} |  | ||||||
| 			break; |  | ||||||
| 		case IDC_RUFUS_MBR: | 		case IDC_RUFUS_MBR: | ||||||
| 			if ((HIWORD(wParam)) == BN_CLICKED) | 			if ((HIWORD(wParam)) == BN_CLICKED) | ||||||
| 				mbr_selected_by_user = IsChecked(IDC_RUFUS_MBR); | 				mbr_selected_by_user = IsChecked(IDC_RUFUS_MBR); | ||||||
|  | @ -3099,7 +3101,7 @@ static INT_PTR CALLBACK MainCallback(HWND hDlg, UINT message, WPARAM wParam, LPA | ||||||
| 			// Show the language menu such that it doesn't overlap the button
 | 			// Show the language menu such that it doesn't overlap the button
 | ||||||
| 			SendMessage(hMultiToolbar, TB_GETRECT, (WPARAM)IDC_ABOUT, (LPARAM)&rc); | 			SendMessage(hMultiToolbar, TB_GETRECT, (WPARAM)IDC_ABOUT, (LPARAM)&rc); | ||||||
| 			MapWindowPoints(hDlg, NULL, (POINT*)&rc, 2); | 			MapWindowPoints(hDlg, NULL, (POINT*)&rc, 2); | ||||||
| 			rc.left += cb_width / 2; | 			rc.left += cbw / 2; | ||||||
| 			ShowLanguageMenu(rc); | 			ShowLanguageMenu(rc); | ||||||
| 			break; | 			break; | ||||||
| 		case IDC_SETTINGS: | 		case IDC_SETTINGS: | ||||||
|  | @ -3197,7 +3199,7 @@ static INT_PTR CALLBACK MainCallback(HWND hDlg, UINT message, WPARAM wParam, LPA | ||||||
| 		safe_release_dc(hDlg, hDC); | 		safe_release_dc(hDlg, hDC); | ||||||
| 		apply_localization(IDD_DIALOG, hDlg); | 		apply_localization(IDD_DIALOG, hDlg); | ||||||
| 		SetUpdateCheck(); | 		SetUpdateCheck(); | ||||||
| 		togo_mode = TRUE;	// We display the ToGo controls by default and need to hide them
 | 		display_togo_option = TRUE;	// We display the ToGo controls by default and need to hide them
 | ||||||
| 		first_log_display = TRUE; | 		first_log_display = TRUE; | ||||||
| 		log_displayed = FALSE; | 		log_displayed = FALSE; | ||||||
| 		hLogDlg = MyCreateDialog(hMainInstance, IDD_LOG, hDlg, (DLGPROC)LogProc); | 		hLogDlg = MyCreateDialog(hMainInstance, IDD_LOG, hDlg, (DLGPROC)LogProc); | ||||||
|  | @ -3275,11 +3277,11 @@ static INT_PTR CALLBACK MainCallback(HWND hDlg, UINT message, WPARAM wParam, LPA | ||||||
| 			lpttt = (LPTOOLTIPTEXT)lParam; | 			lpttt = (LPTOOLTIPTEXT)lParam; | ||||||
| 			switch (lpttt->hdr.idFrom) { | 			switch (lpttt->hdr.idFrom) { | ||||||
| 			case IDC_ABOUT: | 			case IDC_ABOUT: | ||||||
| 				utf8_to_wchar_no_alloc(lmprintf(MSG_306), wtooltip, ARRAYSIZE(wtooltip)); | 				utf8_to_wchar_no_alloc(lmprintf(MSG_302), wtooltip, ARRAYSIZE(wtooltip)); | ||||||
| 				lpttt->lpszText = wtooltip; | 				lpttt->lpszText = wtooltip; | ||||||
| 				break; | 				break; | ||||||
| 			case IDC_SETTINGS: | 			case IDC_SETTINGS: | ||||||
| 				utf8_to_wchar_no_alloc(lmprintf(MSG_305), wtooltip, ARRAYSIZE(wtooltip)); | 				utf8_to_wchar_no_alloc(lmprintf(MSG_301), wtooltip, ARRAYSIZE(wtooltip)); | ||||||
| 				lpttt->lpszText = wtooltip; | 				lpttt->lpszText = wtooltip; | ||||||
| 				break; | 				break; | ||||||
| 			case IDC_LANG: | 			case IDC_LANG: | ||||||
|  | @ -3287,7 +3289,7 @@ static INT_PTR CALLBACK MainCallback(HWND hDlg, UINT message, WPARAM wParam, LPA | ||||||
| 				lpttt->lpszText = wtooltip; | 				lpttt->lpszText = wtooltip; | ||||||
| 				break; | 				break; | ||||||
| 			case IDC_LOG: | 			case IDC_LOG: | ||||||
| 				utf8_to_wchar_no_alloc(lmprintf(MSG_307), wtooltip, ARRAYSIZE(wtooltip)); | 				utf8_to_wchar_no_alloc(lmprintf(MSG_303), wtooltip, ARRAYSIZE(wtooltip)); | ||||||
| 				lpttt->lpszText = wtooltip; | 				lpttt->lpszText = wtooltip; | ||||||
| 				break; | 				break; | ||||||
| 			} | 			} | ||||||
|  |  | ||||||
|  | @ -391,7 +391,7 @@ extern BOOL PromptOnError; | ||||||
| extern unsigned long syslinux_ldlinux_len[2]; | extern unsigned long syslinux_ldlinux_len[2]; | ||||||
| extern const int nb_steps[FS_MAX]; | extern const int nb_steps[FS_MAX]; | ||||||
| extern BOOL use_own_c32[NB_OLD_C32], detect_fakes, iso_op_in_progress, format_op_in_progress, right_to_left_mode; | extern BOOL use_own_c32[NB_OLD_C32], detect_fakes, iso_op_in_progress, format_op_in_progress, right_to_left_mode; | ||||||
| extern BOOL allow_dual_uefi_bios, togo_mode, large_drive, usb_debug; | extern BOOL allow_dual_uefi_bios, display_togo_option, large_drive, usb_debug; | ||||||
| extern RUFUS_IMG_REPORT img_report; | extern RUFUS_IMG_REPORT img_report; | ||||||
| extern int64_t iso_blocking_status; | extern int64_t iso_blocking_status; | ||||||
| extern uint16_t rufus_version[3], embedded_sl_version[2]; | extern uint16_t rufus_version[3], embedded_sl_version[2]; | ||||||
|  |  | ||||||
							
								
								
									
										30
									
								
								src/rufus.rc
									
										
									
									
									
								
							
							
						
						
									
										30
									
								
								src/rufus.rc
									
										
									
									
									
								
							|  | @ -86,10 +86,10 @@ CAPTION "About Rufus" | ||||||
| FONT 9, "Segoe UI Symbol", 400, 0, 0x0 | FONT 9, "Segoe UI Symbol", 400, 0, 0x0 | ||||||
| BEGIN | BEGIN | ||||||
|     ICON            IDI_ICON,IDC_ABOUT_ICON,11,8,20,20 |     ICON            IDI_ICON,IDC_ABOUT_ICON,11,8,20,20 | ||||||
|     CONTROL         "",IDC_ABOUT_BLURB,"RichEdit20W",0x884,45,7,268,107 |     CONTROL         "",IDC_ABOUT_BLURB,"RichEdit20W",ES_MULTILINE | ES_AUTOHSCROLL | ES_READONLY,45,7,268,107 | ||||||
|     CONTROL         "",IDC_ABOUT_COPYRIGHTS,"RichEdit20W",WS_VSCROLL | WS_TABSTOP | 0x804,46,115,267,91,WS_EX_STATICEDGE |     CONTROL         "",IDC_ABOUT_COPYRIGHTS,"RichEdit20W",ES_MULTILINE | ES_READONLY | WS_VSCROLL | WS_TABSTOP,46,115,267,91,WS_EX_STATICEDGE | ||||||
|     PUSHBUTTON      "License",IDC_ABOUT_LICENSE,46,215,50,14,WS_GROUP |     PUSHBUTTON      "License",IDC_ABOUT_LICENSE,46,216,50,12,WS_GROUP | ||||||
|     DEFPUSHBUTTON   "OK",IDOK,251,215,50,14,WS_GROUP |     DEFPUSHBUTTON   "OK",IDOK,253,216,50,12,WS_GROUP | ||||||
| END | END | ||||||
| 
 | 
 | ||||||
| IDD_CHECKSUM DIALOGEX 0, 0, 301, 70 | IDD_CHECKSUM DIALOGEX 0, 0, 301, 70 | ||||||
|  | @ -103,27 +103,27 @@ BEGIN | ||||||
|     EDITTEXT        IDC_SHA1,40,25,197,12,ES_LOWERCASE | ES_AUTOHSCROLL | ES_READONLY |     EDITTEXT        IDC_SHA1,40,25,197,12,ES_LOWERCASE | ES_AUTOHSCROLL | ES_READONLY | ||||||
|     LTEXT           "SHA256:",IDC_STATIC,9,42,27,8 |     LTEXT           "SHA256:",IDC_STATIC,9,42,27,8 | ||||||
|     EDITTEXT        IDC_SHA256,40,41,197,22,ES_MULTILINE | ES_LOWERCASE | ES_READONLY |     EDITTEXT        IDC_SHA256,40,41,197,22,ES_MULTILINE | ES_LOWERCASE | ES_READONLY | ||||||
|     DEFPUSHBUTTON   "OK",IDOK,243,49,50,14,WS_GROUP |     DEFPUSHBUTTON   "OK",IDOK,243,49,50,12,WS_GROUP | ||||||
| END | END | ||||||
| 
 | 
 | ||||||
| IDD_LICENSE DIALOGEX 0, 0, 335, 205 | IDD_LICENSE DIALOGEX 0, 0, 335, 213 | ||||||
| STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU | STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | ||||||
| CAPTION "Rufus License" | CAPTION "Rufus License" | ||||||
| FONT 9, "Segoe UI Symbol", 400, 0, 0x0 | FONT 9, "Segoe UI Symbol", 400, 0, 0x0 | ||||||
| BEGIN | BEGIN | ||||||
|     DEFPUSHBUTTON   "Close",IDCANCEL,278,187,50,14 |     DEFPUSHBUTTON   "Close",IDCANCEL,278,192,50,12 | ||||||
|     EDITTEXT        IDC_LICENSE_TEXT,7,7,321,176,ES_MULTILINE | ES_READONLY | WS_VSCROLL |     EDITTEXT        IDC_LICENSE_TEXT,7,7,321,176,ES_MULTILINE | ES_READONLY | WS_VSCROLL | ||||||
| END | END | ||||||
| 
 | 
 | ||||||
| IDD_LOG DIALOGEX 0, 0, 366, 326 | IDD_LOG DIALOGEX 0, 0, 366, 326 | ||||||
| STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU | STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | ||||||
| CAPTION "Log" | CAPTION "Log" | ||||||
| FONT 9, "Segoe UI Symbol", 400, 0, 0x0 | FONT 9, "Segoe UI Symbol", 400, 0, 0x0 | ||||||
| BEGIN | BEGIN | ||||||
|     EDITTEXT        IDC_LOG_EDIT,0,0,366,296,ES_MULTILINE | ES_READONLY | NOT WS_BORDER | WS_VSCROLL,WS_EX_CLIENTEDGE |     EDITTEXT        IDC_LOG_EDIT,0,0,366,296,ES_MULTILINE | ES_READONLY | NOT WS_BORDER | WS_VSCROLL,WS_EX_CLIENTEDGE | ||||||
|     PUSHBUTTON      "Clear Log",IDC_LOG_CLEAR,198,304,50,14 |     PUSHBUTTON      "Clear",IDC_LOG_CLEAR,192,305,50,12 | ||||||
|     PUSHBUTTON      "Save Log",IDC_LOG_SAVE,253,304,50,14 |     PUSHBUTTON      "Save",IDC_LOG_SAVE,249,305,50,12 | ||||||
|     DEFPUSHBUTTON   "Close Log",IDCANCEL,308,304,50,14 |     DEFPUSHBUTTON   "Close",IDCANCEL,306,305,50,12 | ||||||
| END | END | ||||||
| 
 | 
 | ||||||
| IDD_NOTIFICATION DIALOGEX 0, 0, 263, 63 | IDD_NOTIFICATION DIALOGEX 0, 0, 263, 63 | ||||||
|  | @ -149,8 +149,8 @@ BEGIN | ||||||
|     LTEXT           "",IDC_STATIC,0,0,312,46 |     LTEXT           "",IDC_STATIC,0,0,312,46 | ||||||
|     ICON            IDI_ICON,IDC_SELECTION_ICON,6,6,20,20,0,WS_EX_TRANSPARENT |     ICON            IDI_ICON,IDC_SELECTION_ICON,6,6,20,20,0,WS_EX_TRANSPARENT | ||||||
|     LTEXT           "Message",IDC_SELECTION_TEXT,35,5,269,8 |     LTEXT           "Message",IDC_SELECTION_TEXT,35,5,269,8 | ||||||
|     DEFPUSHBUTTON   "OK",IDOK,196,52,50,14 |     DEFPUSHBUTTON   "OK",IDOK,196,53,50,12 | ||||||
|     PUSHBUTTON      "Cancel",IDCANCEL,254,52,50,14 |     PUSHBUTTON      "Cancel",IDCANCEL,254,53,50,12 | ||||||
|     CONTROL         "Choice 1",IDC_SELECTION_CHOICE1,"Button",BS_AUTORADIOBUTTON | WS_GROUP,35,18,269,10,WS_EX_TRANSPARENT |     CONTROL         "Choice 1",IDC_SELECTION_CHOICE1,"Button",BS_AUTORADIOBUTTON | WS_GROUP,35,18,269,10,WS_EX_TRANSPARENT | ||||||
|     CONTROL         "Choice 2",IDC_SELECTION_CHOICE2,"Button",BS_AUTORADIOBUTTON,35,31,269,10,WS_EX_TRANSPARENT |     CONTROL         "Choice 2",IDC_SELECTION_CHOICE2,"Button",BS_AUTORADIOBUTTON,35,31,269,10,WS_EX_TRANSPARENT | ||||||
|     CONTROL         "Choice 3",IDC_SELECTION_CHOICE3,"Button",BS_AUTORADIOBUTTON | NOT WS_VISIBLE,35,44,269,10,WS_EX_TRANSPARENT |     CONTROL         "Choice 3",IDC_SELECTION_CHOICE3,"Button",BS_AUTORADIOBUTTON | NOT WS_VISIBLE,35,44,269,10,WS_EX_TRANSPARENT | ||||||
|  | @ -178,7 +178,7 @@ BEGIN | ||||||
|     LTEXT           "",IDC_STATIC,0,0,312,31 |     LTEXT           "",IDC_STATIC,0,0,312,31 | ||||||
|     ICON            IDI_ICON,IDC_LIST_ICON,6,6,20,20,0,WS_EX_TRANSPARENT |     ICON            IDI_ICON,IDC_LIST_ICON,6,6,20,20,0,WS_EX_TRANSPARENT | ||||||
|     LTEXT           "Message",IDC_LIST_TEXT,35,5,269,8 |     LTEXT           "Message",IDC_LIST_TEXT,35,5,269,8 | ||||||
|     PUSHBUTTON      "OK",IDOK,254,39,50,14 |     PUSHBUTTON      "OK",IDOK,254,40,50,12 | ||||||
|     LTEXT           "List 1",IDC_LIST_ITEM1,35,17,269,10,SS_PATHELLIPSIS |     LTEXT           "List 1",IDC_LIST_ITEM1,35,17,269,10,SS_PATHELLIPSIS | ||||||
|     LTEXT           "List 2",IDC_LIST_ITEM2,35,28,269,10,SS_PATHELLIPSIS | NOT WS_VISIBLE |     LTEXT           "List 2",IDC_LIST_ITEM2,35,28,269,10,SS_PATHELLIPSIS | NOT WS_VISIBLE | ||||||
|     LTEXT           "List 3",IDC_LIST_ITEM3,35,39,269,10,SS_PATHELLIPSIS | NOT WS_VISIBLE |     LTEXT           "List 3",IDC_LIST_ITEM3,35,39,269,10,SS_PATHELLIPSIS | NOT WS_VISIBLE | ||||||
|  |  | ||||||
							
								
								
									
										15
									
								
								src/stdlg.c
									
										
									
									
									
								
							
							
						
						
									
										15
									
								
								src/stdlg.c
									
										
									
									
									
								
							|  | @ -59,6 +59,7 @@ static HWINEVENTHOOK fp_weh = NULL; | ||||||
| static char *fp_title_str = "Microsoft Windows", *fp_button_str = "Format disk"; | static char *fp_title_str = "Microsoft Windows", *fp_button_str = "Format disk"; | ||||||
| 
 | 
 | ||||||
| extern loc_cmd* selected_locale; | extern loc_cmd* selected_locale; | ||||||
|  | extern int cbw, ddw; | ||||||
| 
 | 
 | ||||||
| /*
 | /*
 | ||||||
|  * https://blogs.msdn.microsoft.com/oldnewthing/20040802-00/?p=38283/
 |  * https://blogs.msdn.microsoft.com/oldnewthing/20040802-00/?p=38283/
 | ||||||
|  | @ -510,10 +511,10 @@ INT_PTR CALLBACK AboutCallback(HWND hDlg, UINT message, WPARAM wParam, LPARAM lP | ||||||
| 	const int edit_id[2] = {IDC_ABOUT_BLURB, IDC_ABOUT_COPYRIGHTS}; | 	const int edit_id[2] = {IDC_ABOUT_BLURB, IDC_ABOUT_COPYRIGHTS}; | ||||||
| 	char about_blurb[2048]; | 	char about_blurb[2048]; | ||||||
| 	const char* edit_text[2] = {about_blurb, additional_copyrights}; | 	const char* edit_text[2] = {about_blurb, additional_copyrights}; | ||||||
| 	HWND hEdit[2]; | 	HWND hEdit[2], hCtrl; | ||||||
| 	TEXTRANGEW tr; | 	TEXTRANGEW tr; | ||||||
| 	ENLINK* enl; | 	ENLINK* enl; | ||||||
| 	RECT rect; | 	RECT rc; | ||||||
| 	REQRESIZE* rsz; | 	REQRESIZE* rsz; | ||||||
| 	wchar_t wUrl[256]; | 	wchar_t wUrl[256]; | ||||||
| 	static BOOL resized_already = TRUE; | 	static BOOL resized_already = TRUE; | ||||||
|  | @ -525,6 +526,12 @@ INT_PTR CALLBACK AboutCallback(HWND hDlg, UINT message, WPARAM wParam, LPARAM lP | ||||||
| 		apply_localization(IDD_ABOUTBOX, hDlg); | 		apply_localization(IDD_ABOUTBOX, hDlg); | ||||||
| 		SetTitleBarIcon(hDlg); | 		SetTitleBarIcon(hDlg); | ||||||
| 		CenterDialog(hDlg); | 		CenterDialog(hDlg); | ||||||
|  | 		// Resize the 'License' button
 | ||||||
|  | 		hCtrl = GetDlgItem(hDlg, IDC_ABOUT_LICENSE); | ||||||
|  | 		GetWindowRect(hCtrl, &rc); | ||||||
|  | 		MapWindowPoints(NULL, hDlg, (POINT*)&rc, 2); | ||||||
|  | 		SetWindowPos(hCtrl, NULL, rc.left, rc.top, | ||||||
|  | 			max(rc.right - rc.left, GetTextSize(hCtrl, NULL).cx + cbw), rc.bottom - rc.top, SWP_NOZORDER); | ||||||
| 		static_sprintf(about_blurb, about_blurb_format, lmprintf(MSG_174|MSG_RTF), | 		static_sprintf(about_blurb, about_blurb_format, lmprintf(MSG_174|MSG_RTF), | ||||||
| 			lmprintf(MSG_175|MSG_RTF, rufus_version[0], rufus_version[1], rufus_version[2]), | 			lmprintf(MSG_175|MSG_RTF, rufus_version[0], rufus_version[1], rufus_version[2]), | ||||||
| 			right_to_left_mode?"Akeo \\\\ Pete Batard 2011-2018 © Copyright":"Copyright © 2011-2018 Pete Batard / Akeo", | 			right_to_left_mode?"Akeo \\\\ Pete Batard 2011-2018 © Copyright":"Copyright © 2011-2018 Pete Batard / Akeo", | ||||||
|  | @ -550,8 +557,8 @@ INT_PTR CALLBACK AboutCallback(HWND hDlg, UINT message, WPARAM wParam, LPARAM lP | ||||||
| 		case EN_REQUESTRESIZE: | 		case EN_REQUESTRESIZE: | ||||||
| 			if (!resized_already) { | 			if (!resized_already) { | ||||||
| 				resized_already = TRUE; | 				resized_already = TRUE; | ||||||
| 				GetWindowRect(GetDlgItem(hDlg, edit_id[0]), &rect); | 				GetWindowRect(GetDlgItem(hDlg, edit_id[0]), &rc); | ||||||
| 				dy = rect.bottom - rect.top; | 				dy = rc.bottom - rc.top; | ||||||
| 				rsz = (REQRESIZE *)lParam; | 				rsz = (REQRESIZE *)lParam; | ||||||
| 				dy -= rsz->rc.bottom - rsz->rc.top; | 				dy -= rsz->rc.bottom - rsz->rc.top; | ||||||
| 				ResizeMoveCtrl(hDlg, GetDlgItem(hDlg, edit_id[0]), 0, 0, 0, -dy, 1.0f); | 				ResizeMoveCtrl(hDlg, GetDlgItem(hDlg, edit_id[0]), 0, 0, 0, -dy, 1.0f); | ||||||
|  |  | ||||||
							
								
								
									
										7
									
								
								src/ui.h
									
										
									
									
									
								
							
							
						
						
									
										7
									
								
								src/ui.h
									
										
									
									
									
								
							|  | @ -152,6 +152,13 @@ static int full_width_controls[] = { | ||||||
| 	IDC_PROGRESS, | 	IDC_PROGRESS, | ||||||
| }; | }; | ||||||
| 
 | 
 | ||||||
|  | static int full_width_checkboxes[] = { | ||||||
|  | 	IDC_LIST_USB_HDD, | ||||||
|  | 	IDC_OLD_BIOS_FIXES, | ||||||
|  | 	IDC_QUICKFORMAT, | ||||||
|  | 	IDC_EXTENDED_LABEL, | ||||||
|  | }; | ||||||
|  | 
 | ||||||
| static int half_width_ids[] = { | static int half_width_ids[] = { | ||||||
| 	IDC_BADBLOCKS, | 	IDC_BADBLOCKS, | ||||||
| 	IDC_RUFUS_MBR, | 	IDC_RUFUS_MBR, | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue