From bb00e220acf808c5912bed559831f72b68b0cb5b Mon Sep 17 00:00:00 2001 From: Pete Batard Date: Wed, 26 Jul 2017 11:47:02 +0100 Subject: [PATCH] [ui] more info field fixes * Prevent text selection and try to force a redraw, to ensure the text is centered on update * Also update the libcdio 'AL' workaround --- src/libcdio/iso9660/rock.c | 8 ++++---- src/localization.c | 3 ++- src/rufus.c | 4 ++++ src/rufus.rc | 10 +++++----- 4 files changed, 15 insertions(+), 10 deletions(-) diff --git a/src/libcdio/iso9660/rock.c b/src/libcdio/iso9660/rock.c index 39ae5696..9e6cdd47 100644 --- a/src/libcdio/iso9660/rock.c +++ b/src/libcdio/iso9660/rock.c @@ -182,12 +182,12 @@ get_rock_ridge_filename(iso9660_dir_t * p_iso9660_dir, case SIG('P','L'): case SIG('T','F'): case SIG('Z','F'): - case SIG('A','L'): // Kali Linux *NONSTANDARD* extension + case SIG('A','L'): // libburnia's AAIP extension (used by Kali Linux) break; default: - /* Warn about other nonstandard Rock Ridge extensions */ - cdio_warn("Invalid Rock Ridge extension detected: '%c%c'\n", *chr, *(chr+1)); - goto out; + /* Warn about other Rock Ridge extensions */ + cdio_warn("Unsupported Rock Ridge extension detected: '%c%c'\n", *chr, *(chr+1)); + break; } if (rr->len == 0) goto out; /* Something got screwed up here */ diff --git a/src/localization.c b/src/localization.c index 256ad849..350443cf 100644 --- a/src/localization.c +++ b/src/localization.c @@ -427,7 +427,8 @@ static uint64_t last_msg_time[2] = { 0, 0 }; static void PrintInfoMessage(char* msg) { SetWindowTextU(hInfo, msg); - Edit_SetSel(hInfo, -1, 0); + // Make sure our field gets redrawn + SendMessage(hInfo, WM_PAINT, 0, 0); } static void PrintStatusMessage(char* msg) { SendMessageLU(hStatus, SB_SETTEXTW, SBT_OWNERDRAW | SB_SECTION_LEFT, msg); diff --git a/src/rufus.c b/src/rufus.c index 6cb773da..063f7ba9 100644 --- a/src/rufus.c +++ b/src/rufus.c @@ -1622,6 +1622,10 @@ static INT_PTR CALLBACK InfoCallback(HWND hCtrl, UINT message, WPARAM wParam, LP switch (message) { + // Prevent text selection (wich Windows seems keen on doing on its own) + case EM_SETSEL: + return (INT_PTR)TRUE; + // Prevent select (which screws up our display as it redraws the font using different settings) case WM_LBUTTONDOWN: return (INT_PTR)FALSE; diff --git a/src/rufus.rc b/src/rufus.rc index b9444533..77ea5ebb 100644 --- a/src/rufus.rc +++ b/src/rufus.rc @@ -33,7 +33,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL IDD_DIALOG DIALOGEX 12, 12, 242, 376 STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU EXSTYLE WS_EX_ACCEPTFILES -CAPTION "Rufus 2.16.1160" +CAPTION "Rufus 2.16.1161" FONT 8, "Segoe UI Symbol", 400, 0, 0x0 BEGIN LTEXT "Device",IDS_DEVICE_TXT,9,6,200,8 @@ -366,8 +366,8 @@ END // VS_VERSION_INFO VERSIONINFO - FILEVERSION 2,16,1160,0 - PRODUCTVERSION 2,16,1160,0 + FILEVERSION 2,16,1161,0 + PRODUCTVERSION 2,16,1161,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -384,13 +384,13 @@ BEGIN BEGIN VALUE "CompanyName", "Akeo Consulting (http://akeo.ie)" VALUE "FileDescription", "Rufus" - VALUE "FileVersion", "2.16.1160" + VALUE "FileVersion", "2.16.1161" VALUE "InternalName", "Rufus" VALUE "LegalCopyright", "© 2011-2017 Pete Batard (GPL v3)" VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/gpl.html" VALUE "OriginalFilename", "rufus.exe" VALUE "ProductName", "Rufus" - VALUE "ProductVersion", "2.16.1160" + VALUE "ProductVersion", "2.16.1161" END END BLOCK "VarFileInfo"