Skip to content

Commit

Permalink
v2.4 (build 755)
Browse files Browse the repository at this point in the history
* Also set global scaling factor before the dialog is initialized and
  remove unneeded scaling initialization.
  • Loading branch information
pbatard committed Sep 27, 2015
1 parent 2b390aa commit ae06a39
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 12 deletions.
4 changes: 2 additions & 2 deletions ChangeLog.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
o Version 2.4 (2015.09.??)
o Version 2.4 (2015.09.27)
Allow some settings and cheat modes to be persisted between sessions
Fix multiple issues with flash drive detection
Fix listing of drives that contain no media
Fix cheat mode to save the current USB to *uncompressed* VHD (Alt-V)
Fix an UI scaling issue with high DPI displays for non English languages
Update most of the translations
Minor cosmetic changes
Additional cosmetic improvements

o Version 2.3 (2015.08.28)
Detect ISOHybrid images and ask users how they should be written
Expand Down
7 changes: 7 additions & 0 deletions src/rufus.c
Original file line number Diff line number Diff line change
Expand Up @@ -2749,6 +2749,7 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine
PF_TYPE_DECL(CDECL, int, __wgetmainargs, (int*, wchar_t***, wchar_t***, int, int*));
HANDLE mutex = NULL, hogmutex = NULL, hFile = NULL;
HWND hDlg = NULL;
HDC hDC;
MSG msg;
struct option long_options[] = {
{"fixed", no_argument, NULL, 'f'},
Expand Down Expand Up @@ -2888,6 +2889,12 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine
force_large_fat32 = ReadSettingBool(SETTING_FORCE_LARGE_FAT32_FORMAT);
enable_vmdk = ReadSettingBool(SETTING_ENABLE_VMDK_DETECTION);

// Initialize the global scaling, in case we need it before we initialize the dialog
hDC = GetDC(NULL);
fScale = GetDeviceCaps(hDC, LOGPIXELSX) / 96.0f;
if (hDC != NULL)
ReleaseDC(NULL, hDC);

// Init localization
init_localization();
// Seek for a loc file in the current directory
Expand Down
10 changes: 5 additions & 5 deletions src/rufus.rc
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,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
CAPTION "Rufus 2.4.754"
CAPTION "Rufus 2.4.755"
FONT 8, "Segoe UI Symbol", 400, 0, 0x0
BEGIN
LTEXT "Device",IDS_DEVICE_TXT,9,6,200,8
Expand Down Expand Up @@ -317,8 +317,8 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 2,4,754,0
PRODUCTVERSION 2,4,754,0
FILEVERSION 2,4,755,0
PRODUCTVERSION 2,4,755,0
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -335,13 +335,13 @@ BEGIN
BEGIN
VALUE "CompanyName", "Akeo Consulting (http://akeo.ie)"
VALUE "FileDescription", "Rufus"
VALUE "FileVersion", "2.4.754"
VALUE "FileVersion", "2.4.755"
VALUE "InternalName", "Rufus"
VALUE "LegalCopyright", "� 2011-2015 Pete Batard (GPL v3)"
VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/gpl.html"
VALUE "OriginalFilename", "rufus.exe"
VALUE "ProductName", "Rufus"
VALUE "ProductVersion", "2.4.754"
VALUE "ProductVersion", "2.4.755"
END
END
BLOCK "VarFileInfo"
Expand Down
5 changes: 0 additions & 5 deletions src/stdlg.c
Original file line number Diff line number Diff line change
Expand Up @@ -1557,16 +1557,11 @@ void DownloadNewVersion(void)

void SetTitleBarIcon(HWND hDlg)
{
HDC hDC;
int i16, s16, s32;
HICON hSmallIcon, hBigIcon;

// High DPI scaling
i16 = GetSystemMetrics(SM_CXSMICON);
hDC = GetDC(hDlg);
fScale = GetDeviceCaps(hDC, LOGPIXELSX) / 96.0f;
if (hDC != NULL)
ReleaseDC(hDlg, hDC);
// Adjust icon size lookup
s16 = i16;
s32 = (int)(32.0f*fScale);
Expand Down

0 comments on commit ae06a39

Please sign in to comment.