10 Nov
2025
10 Nov
'25
9:42 a.m.
Nikolay Sivov (@nsivov) commented about dlls/comctl32/progress.c:
return GetWindowLongW(hwnd, GWL_STYLE) & PBS_SMOOTH; }
+static const ProgressDrawProc *PROGRESS_GetDrawProcs(HWND hwnd, BOOL smooth, DWORD style) +{ + int proc_idx = (smooth ? 0 : 4) + ((style & PBS_VERTICAL) ? 2 : 0);
It's en existing thing, but I still want to mention it. This is not going to use all 8 drawing functions, any idea why we have 8 of them? If all we need is 4 states, this should be made more obvious, for example
drawProcThemed[!!smooth][!!(style & PBS_VERTICAL)]
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/9409#note_121324