summaryrefslogtreecommitdiff
path: root/src/strings.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2015-08-09 12:33:27 +0000
committerrubidium <rubidium@openttd.org>2015-08-09 12:33:27 +0000
commit69fac508c386f660be4428a1e58da30ec0acd9a1 (patch)
tree7a0fd9a382b0e7dec5966bc7e50f249021d9f91a /src/strings.cpp
parentbdf090b406e87ff2d0a3f3c5b6dc92b4c232dc3c (diff)
downloadopenttd-69fac508c386f660be4428a1e58da30ec0acd9a1.tar.xz
(svn r27367) -Codechange: make a distinction between the layouting part of ICU (lx) or the sorting/collation part of ICU (i18n)
Diffstat (limited to 'src/strings.cpp')
-rw-r--r--src/strings.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/strings.cpp b/src/strings.cpp
index 9c88b70c7..5d1059243 100644
--- a/src/strings.cpp
+++ b/src/strings.cpp
@@ -49,9 +49,9 @@ const LanguageMetadata *_current_language = NULL; ///< The currently loaded lang
TextDirection _current_text_dir; ///< Text direction of the currently selected language.
-#ifdef WITH_ICU
+#ifdef WITH_ICU_SORT
Collator *_current_collator = NULL; ///< Collator for the language currently in use.
-#endif /* WITH_ICU */
+#endif /* WITH_ICU_SORT */
static uint64 _global_string_params_data[20]; ///< Global array of string parameters. To access, use #SetDParam.
static WChar _global_string_params_type[20]; ///< Type of parameters stored in #_decode_parameters
@@ -1790,7 +1790,7 @@ bool ReadLanguagePack(const LanguageMetadata *lang)
strecpy(_config_language_file, c_file, lastof(_config_language_file));
SetCurrentGrfLangID(_current_language->newgrflangid);
-#ifdef WITH_ICU
+#ifdef WITH_ICU_SORT
/* Delete previous collator. */
if (_current_collator != NULL) {
delete _current_collator;
@@ -1807,7 +1807,7 @@ bool ReadLanguagePack(const LanguageMetadata *lang)
delete _current_collator;
_current_collator = NULL;
}
-#endif /* WITH_ICU */
+#endif /* WITH_ICU_SORT */
/* Some lists need to be sorted again after a language change. */
ReconsiderGameScriptLanguage();
@@ -2132,7 +2132,7 @@ void CheckForMissingGlyphs(bool base_font, MissingGlyphSearcher *searcher)
/* Update the font with cache */
LoadStringWidthTable(searcher->Monospace());
-#if !defined(WITH_ICU)
+#if !defined(WITH_ICU_LAYOUT)
/*
* For right-to-left languages we need the ICU library. If
* we do not have support for that library we warn the user
@@ -2152,5 +2152,5 @@ void CheckForMissingGlyphs(bool base_font, MissingGlyphSearcher *searcher)
SetDParamStr(0, err_str);
ShowErrorMessage(STR_JUST_RAW_STRING, INVALID_STRING_ID, WL_ERROR);
}
-#endif
+#endif /* !WITH_ICU_LAYOUT */
}