mirror of
https://github.com/pbatard/rufus.git
synced 2024-08-14 23:57:05 +00:00
[ui] prevent the toolbars from disappearing
* Seriously, who at Microsoft devised this utterly broken TB_GETIDEALSIZE call?
This commit is contained in:
parent
180e6d4364
commit
0186949255
2 changed files with 10 additions and 5 deletions
10
src/rufus.rc
10
src/rufus.rc
|
@ -33,7 +33,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
|
|||
IDD_DIALOG DIALOGEX 12, 12, 232, 326
|
||||
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||
EXSTYLE WS_EX_ACCEPTFILES
|
||||
CAPTION "Rufus 3.6.1544"
|
||||
CAPTION "Rufus 3.6.1545"
|
||||
FONT 9, "Segoe UI Symbol", 400, 0, 0x0
|
||||
BEGIN
|
||||
LTEXT "Drive Properties",IDS_DRIVE_PROPERTIES_TXT,8,6,53,12,NOT WS_GROUP
|
||||
|
@ -394,8 +394,8 @@ END
|
|||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 3,6,1544,0
|
||||
PRODUCTVERSION 3,6,1544,0
|
||||
FILEVERSION 3,6,1545,0
|
||||
PRODUCTVERSION 3,6,1545,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
|
@ -413,13 +413,13 @@ BEGIN
|
|||
VALUE "Comments", "https://akeo.ie"
|
||||
VALUE "CompanyName", "Akeo Consulting"
|
||||
VALUE "FileDescription", "Rufus"
|
||||
VALUE "FileVersion", "3.6.1544"
|
||||
VALUE "FileVersion", "3.6.1545"
|
||||
VALUE "InternalName", "Rufus"
|
||||
VALUE "LegalCopyright", "© 2011-2019 Pete Batard (GPL v3)"
|
||||
VALUE "LegalTrademarks", "https://www.gnu.org/copyleft/gpl.html"
|
||||
VALUE "OriginalFilename", "rufus-3.6.exe"
|
||||
VALUE "ProductName", "Rufus"
|
||||
VALUE "ProductVersion", "3.6.1544"
|
||||
VALUE "ProductVersion", "3.6.1545"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
|
|
5
src/ui.c
5
src/ui.c
|
@ -595,6 +595,9 @@ void ToggleAdvancedDeviceOptions(BOOL enable)
|
|||
GetWindowRect(hAdvancedDeviceToolbar, &rc);
|
||||
MapWindowPoints(NULL, hMainDialog, (POINT*)&rc, 2);
|
||||
SendMessage(hAdvancedDeviceToolbar, TB_GETIDEALSIZE, (WPARAM)FALSE, (LPARAM)&sz);
|
||||
// TB_GETIDEALSIZE may act up and report negative values
|
||||
if (sz.cx < 16)
|
||||
sz.cx = fw;
|
||||
SetWindowPos(hAdvancedDeviceToolbar, hTargetSystem, rc.left, rc.top, sz.cx, rc.bottom - rc.top, 0);
|
||||
|
||||
// Move the controls up or down
|
||||
|
@ -637,6 +640,8 @@ void ToggleAdvancedFormatOptions(BOOL enable)
|
|||
GetWindowRect(hAdvancedFormatToolbar, &rc);
|
||||
MapWindowPoints(NULL, hMainDialog, (POINT*)&rc, 2);
|
||||
SendMessage(hAdvancedFormatToolbar, TB_GETIDEALSIZE, (WPARAM)FALSE, (LPARAM)&sz);
|
||||
if (sz.cx < 16)
|
||||
sz.cx = fw;
|
||||
SetWindowPos(hAdvancedFormatToolbar, hClusterSize, rc.left, rc.top, sz.cx, rc.bottom - rc.top, 0);
|
||||
|
||||
// Move the controls up or down
|
||||
|
|
Loading…
Reference in a new issue