17 Jul
2018
17 Jul
'18
7:48 a.m.
Nikolay Sivov <nsivov(a)codeweavers.com> writes:
@@ -1488,6 +1489,10 @@ TRACKBAR_InitializeThumb (TRACKBAR_INFO *infoPtr) else infoPtr->uThumbLen = clientWidth > 9 ? clientWidth - 6 : 4;
+ hdc = GetDC(infoPtr->hwndSelf); + infoPtr->uThumbLen = MulDiv(infoPtr->uThumbLen, GetDeviceCaps(hdc, LOGPIXELSX), 96); + ReleaseDC(infoPtr->hwndSelf, hdc);
You probably want to use GetDpiForWindow() instead. Also it seems to me that the check against the client rect should be done after scaling. -- Alexandre Julliard julliard(a)winehq.org