[i18n] rework localization system

Signed-off-by: R4SAS <r4sas@i2pmail.org>
This commit is contained in:
R4SAS 2021-05-25 22:03:29 +03:00
parent 1a4250d8cc
commit 779f2fa451
No known key found for this signature in database
GPG key ID: 66F6C87B98EBCFE2
7 changed files with 111 additions and 109 deletions

View file

@ -32,6 +32,7 @@
#include "UPnP.h"
#include "Timestamp.h"
#include "util.h"
#include "I18N.h"
namespace i2p
{
@ -345,10 +346,7 @@ namespace util
}
std::string httpLang; i2p::config::GetOption("http.lang", httpLang);
if (!httpLang.compare("russian"))
i2p::context.SetLanguage (eRussian);
else
i2p::context.SetLanguage (eEnglish);
i2p::i18n::SetLanguage(httpLang);
return true;
}