(svn r22806) -Codechange: store the number of untranslated strings in the language file

This commit is contained in:
rubidium
2011-08-21 19:21:38 +00:00
parent f6b0561cd8
commit 525e2c9e73
3 changed files with 12 additions and 2 deletions

View File

@@ -1061,10 +1061,16 @@ static void WriteLangfile(const char *filename)
in_use[i] = n;
_lang.offsets[i] = TO_LE16(n);
for (uint j = 0; j != in_use[i]; j++) {
const LangString *ls = _strings[(i << 11) + j];
if (ls != NULL && ls->translated == NULL) _lang.missing++;
}
}
_lang.ident = TO_LE32(LanguagePackHeader::IDENT);
_lang.version = TO_LE32(_hash);
_lang.missing = TO_LE16(_lang.missing);
_lang.winlangid = TO_LE16(_lang.winlangid);
fwrite(&_lang, sizeof(_lang), 1, _output_file);