Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blentranslation/intern/blt_lang.c
| Show All 36 Lines | |||||
| #include "BLT_lang.h" /* own include */ | #include "BLT_lang.h" /* own include */ | ||||
| #include "BLI_path_util.h" | #include "BLI_path_util.h" | ||||
| #include "BLI_string.h" | #include "BLI_string.h" | ||||
| #include "BLI_utildefines.h" | #include "BLI_utildefines.h" | ||||
| #include "BKE_appdir.h" | #include "BKE_appdir.h" | ||||
| #include "IMB_thumbs.h" | |||||
| #include "DNA_userdef_types.h" | #include "DNA_userdef_types.h" | ||||
| #include "MEM_guardedalloc.h" | #include "MEM_guardedalloc.h" | ||||
| /* Cached IME support flags */ | /* Cached IME support flags */ | ||||
| static bool ime_is_lang_supported = false; | static bool ime_is_lang_supported = false; | ||||
| static void blt_lang_check_ime_supported(void); | static void blt_lang_check_ime_supported(void); | ||||
| ▲ Show 20 Lines • Show All 230 Lines • ▼ Show 20 Lines | #ifdef WITH_INTERNATIONAL | ||||
| } | } | ||||
| else { | else { | ||||
| bl_locale_set(short_locale); | bl_locale_set(short_locale); | ||||
| } | } | ||||
| #else | #else | ||||
| (void)str; | (void)str; | ||||
| #endif | #endif | ||||
| blt_lang_check_ime_supported(); | blt_lang_check_ime_supported(); | ||||
| IMB_thumb_clear_translations(); | |||||
| } | } | ||||
| /* Get the current locale (short code, e.g. es_ES). */ | /* Get the current locale (short code, e.g. es_ES). */ | ||||
| const char *BLT_lang_get(void) | const char *BLT_lang_get(void) | ||||
| { | { | ||||
| #ifdef WITH_INTERNATIONAL | #ifdef WITH_INTERNATIONAL | ||||
| if (BLT_translate()) { | if (BLT_translate()) { | ||||
| const char *locale = LOCALE(ULANGUAGE); | const char *locale = LOCALE(ULANGUAGE); | ||||
| ▲ Show 20 Lines • Show All 109 Lines • Show Last 20 Lines | |||||