http://bugs.winehq.org/show_bug.cgi?id=7571
------- Additional Comments From dmitry@codeweavers.com 2007-21-05 23:14 ------- In general, this patch is much better, but needs some cleanup.
if (enum_gdi_fonts) ret = WineEngEnumFonts( plf, FONT_EnumInstance, (LPARAM)&fe32 );
- if (dwUnicode & ENUM_ALL_FAMILIES) fe32.dwFlags &= ~ENUM_ALL_FAMILIES; fe32.dwFlags &= ~ENUM_CALLED;
You can just unconditionally remove ENUM_ALL_FAMILIES mask simultaneously with ENUM_CALLED.
In order to simplify the logic why not just introduce 1 additional BOOL param to WineEngEnumFonts that would mean ENUM_ALL_FAMILIES? That way there is no need to expose an internal structure and flags to freetype.c.