mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-13 12:39:56 +00:00
GUI: Fix bug in ThemeEngine::addFont related to localized fonts
Basically, it was remembering the font under its non-localized name. This resulted in a leak, and potentially could have caused the wrong font to be used in a localization. svn-id: r54256
This commit is contained in:
parent
8799db594e
commit
3450f47667
@ -575,7 +575,7 @@ bool ThemeEngine::addFont(TextData textId, const Common::String &file) {
|
||||
_texts[textId]->_fontPtr = loadFont(localized);
|
||||
|
||||
if (_texts[textId]->_fontPtr)
|
||||
FontMan.assignFontToName(file, _texts[textId]->_fontPtr);
|
||||
FontMan.assignFontToName(localized, _texts[textId]->_fontPtr);
|
||||
|
||||
// Fallback to non-localized font and default translation
|
||||
else {
|
||||
|
Loading…
Reference in New Issue
Block a user