Use DPI Aware wxSystemParametersInfo

Require a wxWindow when requesting GetNonClientMetrics.
If no wxWindow is known, use wxTheApp->GetTopWindow().
This commit is contained in:
Maarten Bent
2018-07-22 14:21:36 +02:00
parent c0c6a4b826
commit 0a79c48631
4 changed files with 15 additions and 8 deletions

View File

@@ -363,7 +363,7 @@ void MenuDrawData::Init()
else
#endif // wxUSE_UXTHEME
{
const NONCLIENTMETRICS& metrics = wxMSWImpl::GetNonClientMetrics();
const NONCLIENTMETRICS& metrics = wxMSWImpl::GetNonClientMetrics(window);
CheckMargin.cxLeftWidth =
CheckMargin.cxRightWidth = wxGetSystemMetrics(SM_CXEDGE, window);