|
@@ -99,13 +99,14 @@ protected:
|
|
|
}
|
|
|
};
|
|
|
|
|
|
-CLegacyConfigParser::CLegacyConfigParser(std::string URI):
|
|
|
- CLegacyConfigParser(CResourceHandler::get()->load(ResourceID(URI, EResType::TEXT)))
|
|
|
+CLegacyConfigParser::CLegacyConfigParser(std::string URI)
|
|
|
{
|
|
|
-}
|
|
|
+ ResourceID resource(URI, EResType::TEXT);
|
|
|
+ auto input = CResourceHandler::get()->load(resource);
|
|
|
+ std::string modName = VLC->modh->findResourceOrigin(resource);
|
|
|
+ std::string language = VLC->modh->getModLanguage(modName);
|
|
|
+ fileEncoding = Languages::getLanguageOptions(language).encoding;
|
|
|
|
|
|
-CLegacyConfigParser::CLegacyConfigParser(const std::unique_ptr<CInputStream> & input)
|
|
|
-{
|
|
|
data.reset(new char[input->getSize()]);
|
|
|
input->read(reinterpret_cast<uint8_t*>(data.get()), input->getSize());
|
|
|
|