From: <sv...@op...> - 2024-11-10 17:31:50
|
Author: sagamusix Date: Sun Nov 10 18:31:38 2024 New Revision: 22147 URL: https://source.openmpt.org/browse/openmpt/?op=revision&rev=22147 Log: Merged revision(s) 22146 from trunk/OpenMPT: [Fix] Fix truncated display of first item in checkbox lists in particular on high-DPI displays. Potentially also fixes https://bugs.openmpt.org/view.php?id=1480 ........ Modified: branches/OpenMPT-1.31/ (props changed) branches/OpenMPT-1.31/mptrack/GeneralConfigDlg.cpp branches/OpenMPT-1.31/mptrack/dlg_misc.cpp Modified: branches/OpenMPT-1.31/mptrack/GeneralConfigDlg.cpp ============================================================================== --- branches/OpenMPT-1.31/mptrack/GeneralConfigDlg.cpp Sun Nov 10 18:29:25 2024 (r22146) +++ branches/OpenMPT-1.31/mptrack/GeneralConfigDlg.cpp Sun Nov 10 18:31:38 2024 (r22147) @@ -137,6 +137,7 @@ m_CheckList.SetCheck(idx, check); } m_CheckList.SetCurSel(0); + m_CheckList.SetItemHeight(0, 0); // Workaround to force MFC to correctly compute the height of the first list item, in particular on high-DPI setups OnOptionSelChanged(); return TRUE; Modified: branches/OpenMPT-1.31/mptrack/dlg_misc.cpp ============================================================================== --- branches/OpenMPT-1.31/mptrack/dlg_misc.cpp Sun Nov 10 18:29:25 2024 (r22146) +++ branches/OpenMPT-1.31/mptrack/dlg_misc.cpp Sun Nov 10 18:31:38 2024 (r22147) @@ -525,6 +525,7 @@ BOOL CLegacyPlaybackSettingsDlg::OnInitDialog() { ResizableDialog::OnInitDialog(); + m_CheckList.SetItemHeight(0, 0); // Workaround to force MFC to correctly compute the height of the first list item, in particular on high-DPI setups OnFilterStringChanged(); UpdateSelectDefaults(); return TRUE; |