Generalizar la selección de idioma

Signed-off-by: somebody_master <somebody_master@somebodyserver.mooo.com>
This commit is contained in:
Somebody Master 2020-10-28 13:31:33 +01:00
parent fbbef585d2
commit 67c4c4d4d5
Signed by: somebody_master
GPG Key ID: 78315CFDF0B25505

View File

@ -22,9 +22,9 @@ std::string txt::g_confHilosInput = "";
std::string txt::g_confTiempoInput = "";
void txt::inicializarIdioma(std::string idioma){
idioma = idioma.substr(0, idioma.find("."));
idioma = idioma.substr(0, idioma.find("_"));
if(idioma == "gl_ES"){
if(idioma == "gl"){
using namespace gl;
txt::g_noColor = noColor;
txt::g_errorGenerico_1 = errorGenerico_1;
@ -43,7 +43,7 @@ void txt::inicializarIdioma(std::string idioma){
txt::g_confTiempo = confTiempo;
txt::g_confHilosInput = confHilosInput;
txt::g_confTiempoInput = confTiempoInput;
}else if(idioma == "es_ES"){
}else if(idioma == "es"){
using namespace es;
txt::g_noColor = noColor;
txt::g_errorGenerico_1 = errorGenerico_1;
@ -62,7 +62,7 @@ void txt::inicializarIdioma(std::string idioma){
txt::g_confTiempo = confTiempo;
txt::g_confHilosInput = confHilosInput;
txt::g_confTiempoInput = confTiempoInput;
}else if(idioma == "en_US" || idioma == "en_EN"){
}else if(idioma == "en"){
using namespace en;
txt::g_noColor = noColor;
txt::g_errorGenerico_1 = errorGenerico_1;