Preliminary support for the Vietnamese language

This commit is contained in:
Jean-André Santoni 2016-10-27 20:49:15 +02:00
parent 9a1dd5f3cb
commit c99b4f7252
6 changed files with 16 additions and 1 deletions

View File

@ -246,7 +246,8 @@ OBJ += intl/msg_hash_de.o \
intl/msg_hash_nl.o \
intl/msg_hash_pl.o \
intl/msg_hash_pt.o \
intl/msg_hash_ru.o
intl/msg_hash_ru.o \
intl/msg_hash_vn.o
endif

View File

@ -4633,6 +4633,8 @@ const char *msg_hash_to_str_us(enum msg_hash_enums msg)
return "Chinese (Simplified)";
case MENU_ENUM_LABEL_VALUE_LANG_ESPERANTO:
return "Esperanto";
case MENU_ENUM_LABEL_VALUE_LANG_VIETNAMESE:
return "Vietnamese";
case MENU_ENUM_LABEL_VALUE_LEFT_ANALOG:
return "Left Analog";
case MENU_ENUM_LABEL_VALUE_RIGHT_ANALOG:

View File

@ -244,6 +244,7 @@ enum retro_language
RETRO_LANGUAGE_CHINESE_SIMPLIFIED = 11,
RETRO_LANGUAGE_ESPERANTO = 12,
RETRO_LANGUAGE_POLISH = 13,
RETRO_LANGUAGE_VIETNAMESE = 14,
RETRO_LANGUAGE_LAST,
/* Ensure sizeof(enum) == sizeof(int) */

View File

@ -470,6 +470,7 @@ static void setting_get_string_representation_uint_user_language(void *data,
modes[RETRO_LANGUAGE_CHINESE_SIMPLIFIED] = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_LANG_CHINESE_SIMPLIFIED);
modes[RETRO_LANGUAGE_ESPERANTO] = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_LANG_ESPERANTO);
modes[RETRO_LANGUAGE_POLISH] = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_LANG_POLISH);
modes[RETRO_LANGUAGE_VIETNAMESE] = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_LANG_VIETNAMESE);
if (settings)
strlcpy(s, modes[settings->user_language], len);

View File

@ -65,6 +65,9 @@ int menu_hash_get_help_enum(enum msg_hash_enums msg, char *s, size_t len)
case RETRO_LANGUAGE_JAPANESE:
ret = menu_hash_get_help_jp_enum(msg, s, len);
break;
case RETRO_LANGUAGE_VIETNAMESE:
ret = menu_hash_get_help_vn_enum(msg, s, len);
break;
default:
break;
}
@ -118,6 +121,9 @@ const char *msg_hash_to_str(enum msg_hash_enums msg)
case RETRO_LANGUAGE_JAPANESE:
ret = msg_hash_to_str_jp(msg);
break;
case RETRO_LANGUAGE_VIETNAMESE:
ret = msg_hash_to_str_vn(msg);
break;
default:
break;
}

View File

@ -1859,6 +1859,7 @@ enum msg_hash_enums
MENU_ENUM_LABEL_VALUE_LANG_CHINESE_SIMPLIFIED,
MENU_ENUM_LABEL_VALUE_LANG_ESPERANTO,
MENU_ENUM_LABEL_VALUE_LANG_POLISH,
MENU_ENUM_LABEL_VALUE_LANG_VIETNAMESE,
MENU_ENUM_LABEL_VALUE_NONE,
@ -2238,6 +2239,9 @@ int menu_hash_get_help_pl_enum(enum msg_hash_enums msg, char *s, size_t len);
const char *msg_hash_to_str_nl(enum msg_hash_enums msg);
int menu_hash_get_help_nl_enum(enum msg_hash_enums msg, char *s, size_t len);
const char *msg_hash_to_str_vn(enum msg_hash_enums msg);
int menu_hash_get_help_vn_enum(enum msg_hash_enums msg, char *s, size_t len);
const char *msg_hash_to_str_us(enum msg_hash_enums msg);
int menu_hash_get_help_us_enum(enum msg_hash_enums msg, char *s, size_t len);