mirror of
https://github.com/godotengine/godot.git
synced 2025-10-19 16:03:29 +00:00
Merge pull request #97923 from kisg/translation_server_siof_fix
Make TranslationServer singleton variable inline.
This commit is contained in:
commit
ebf49317a2
2 changed files with 1 additions and 3 deletions
|
@ -411,8 +411,6 @@ StringName TranslationServer::translate_plural(const StringName &p_message, cons
|
||||||
return main_domain->translate_plural(p_message, p_message_plural, p_n, p_context);
|
return main_domain->translate_plural(p_message, p_message_plural, p_n, p_context);
|
||||||
}
|
}
|
||||||
|
|
||||||
TranslationServer *TranslationServer::singleton = nullptr;
|
|
||||||
|
|
||||||
bool TranslationServer::_load_translations(const String &p_from) {
|
bool TranslationServer::_load_translations(const String &p_from) {
|
||||||
if (ProjectSettings::get_singleton()->has_setting(p_from)) {
|
if (ProjectSettings::get_singleton()->has_setting(p_from)) {
|
||||||
const Vector<String> &translation_names = GLOBAL_GET(p_from);
|
const Vector<String> &translation_names = GLOBAL_GET(p_from);
|
||||||
|
|
|
@ -50,7 +50,7 @@ class TranslationServer : public Object {
|
||||||
|
|
||||||
bool enabled = true;
|
bool enabled = true;
|
||||||
|
|
||||||
static TranslationServer *singleton;
|
static inline TranslationServer *singleton = nullptr;
|
||||||
bool _load_translations(const String &p_from);
|
bool _load_translations(const String &p_from);
|
||||||
String _standardize_locale(const String &p_locale, bool p_add_defaults) const;
|
String _standardize_locale(const String &p_locale, bool p_add_defaults) const;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue