diff options
Diffstat (limited to 'core/fxge/cfx_unicodeencodingex.cpp')
-rw-r--r-- | core/fxge/cfx_unicodeencodingex.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/core/fxge/cfx_unicodeencodingex.cpp b/core/fxge/cfx_unicodeencodingex.cpp index 3f28d4295e..a8db745612 100644 --- a/core/fxge/cfx_unicodeencodingex.cpp +++ b/core/fxge/cfx_unicodeencodingex.cpp @@ -93,9 +93,8 @@ std::unique_ptr<CFX_UnicodeEncodingEx> FX_CreateFontEncodingEx( if (nEncodingID != FXFM_ENCODING_NONE) return FXFM_CreateFontEncoding(pFont, nEncodingID); - for (size_t i = 0; i < FX_ArraySize(g_EncodingID); ++i) { - std::unique_ptr<CFX_UnicodeEncodingEx> pFontEncoding = - FXFM_CreateFontEncoding(pFont, g_EncodingID[i]); + for (uint32_t id : g_EncodingID) { + auto pFontEncoding = FXFM_CreateFontEncoding(pFont, id); if (pFontEncoding) return pFontEncoding; } |