feat: modules moved and engine moved to submodule
This commit is contained in:
parent
dfb5e645cd
commit
c33d2130cc
5136 changed files with 225275 additions and 64485 deletions
|
|
@ -42,7 +42,7 @@
|
|||
Vector<String> get_editor_locales() {
|
||||
Vector<String> locales;
|
||||
|
||||
EditorTranslationList *etl = _editor_translations;
|
||||
const EditorTranslationList *etl = _editor_translations;
|
||||
while (etl->data) {
|
||||
const String &locale = etl->lang;
|
||||
locales.push_back(locale);
|
||||
|
|
@ -56,7 +56,7 @@ Vector<String> get_editor_locales() {
|
|||
void load_editor_translations(const String &p_locale) {
|
||||
const Ref<TranslationDomain> domain = TranslationServer::get_singleton()->get_or_add_domain("godot.editor");
|
||||
|
||||
EditorTranslationList *etl = _editor_translations;
|
||||
const EditorTranslationList *etl = _editor_translations;
|
||||
while (etl->data) {
|
||||
if (etl->lang == p_locale) {
|
||||
Vector<uint8_t> data;
|
||||
|
|
@ -84,7 +84,7 @@ void load_editor_translations(const String &p_locale) {
|
|||
void load_property_translations(const String &p_locale) {
|
||||
const Ref<TranslationDomain> domain = TranslationServer::get_singleton()->get_or_add_domain("godot.properties");
|
||||
|
||||
PropertyTranslationList *etl = _property_translations;
|
||||
const PropertyTranslationList *etl = _property_translations;
|
||||
while (etl->data) {
|
||||
if (etl->lang == p_locale) {
|
||||
Vector<uint8_t> data;
|
||||
|
|
@ -112,7 +112,7 @@ void load_property_translations(const String &p_locale) {
|
|||
void load_doc_translations(const String &p_locale) {
|
||||
const Ref<TranslationDomain> domain = TranslationServer::get_singleton()->get_or_add_domain("godot.documentation");
|
||||
|
||||
DocTranslationList *dtl = _doc_translations;
|
||||
const DocTranslationList *dtl = _doc_translations;
|
||||
while (dtl->data) {
|
||||
if (dtl->lang == p_locale) {
|
||||
Vector<uint8_t> data;
|
||||
|
|
@ -140,7 +140,7 @@ void load_doc_translations(const String &p_locale) {
|
|||
void load_extractable_translations(const String &p_locale) {
|
||||
const Ref<TranslationDomain> domain = TranslationServer::get_singleton()->get_or_add_domain("godot.editor");
|
||||
|
||||
ExtractableTranslationList *etl = _extractable_translations;
|
||||
const ExtractableTranslationList *etl = _extractable_translations;
|
||||
while (etl->data) {
|
||||
if (etl->lang == p_locale) {
|
||||
Vector<uint8_t> data;
|
||||
|
|
@ -166,7 +166,7 @@ void load_extractable_translations(const String &p_locale) {
|
|||
}
|
||||
|
||||
Vector<Vector<String>> get_extractable_message_list() {
|
||||
ExtractableTranslationList *etl = _extractable_translations;
|
||||
const ExtractableTranslationList *etl = _extractable_translations;
|
||||
Vector<Vector<String>> list;
|
||||
|
||||
while (etl->data) {
|
||||
|
|
@ -235,7 +235,7 @@ Vector<Vector<String>> get_extractable_message_list() {
|
|||
list.push_back(msgs);
|
||||
}
|
||||
msg_context = "";
|
||||
l = l.substr(7, l.length()).strip_edges();
|
||||
l = l.substr(7).strip_edges();
|
||||
status = STATUS_READING_CONTEXT;
|
||||
entered_context = true;
|
||||
}
|
||||
|
|
@ -244,7 +244,7 @@ Vector<Vector<String>> get_extractable_message_list() {
|
|||
if (status != STATUS_READING_ID) {
|
||||
ERR_FAIL_V_MSG(Vector<Vector<String>>(), "Unexpected 'msgid_plural', was expecting 'msgid' before 'msgid_plural' while parsing: " + path + ":" + itos(line));
|
||||
}
|
||||
l = l.substr(12, l.length()).strip_edges();
|
||||
l = l.substr(12).strip_edges();
|
||||
status = STATUS_READING_PLURAL;
|
||||
} else if (l.begins_with("msgid")) {
|
||||
ERR_FAIL_COND_V_MSG(status == STATUS_READING_ID, Vector<Vector<String>>(), "Unexpected 'msgid', was expecting 'msgstr' while parsing: " + path + ":" + itos(line));
|
||||
|
|
@ -257,7 +257,7 @@ Vector<Vector<String>> get_extractable_message_list() {
|
|||
list.push_back(msgs);
|
||||
}
|
||||
|
||||
l = l.substr(5, l.length()).strip_edges();
|
||||
l = l.substr(5).strip_edges();
|
||||
status = STATUS_READING_ID;
|
||||
// If we did not encounter msgctxt, we reset context to empty to reset it.
|
||||
if (!entered_context) {
|
||||
|
|
@ -271,11 +271,11 @@ Vector<Vector<String>> get_extractable_message_list() {
|
|||
if (l.begins_with("msgstr[")) {
|
||||
ERR_FAIL_COND_V_MSG(status != STATUS_READING_PLURAL, Vector<Vector<String>>(),
|
||||
"Unexpected 'msgstr[]', was expecting 'msgid_plural' before 'msgstr[]' while parsing: " + path + ":" + itos(line));
|
||||
l = l.substr(9, l.length()).strip_edges();
|
||||
l = l.substr(9).strip_edges();
|
||||
} else if (l.begins_with("msgstr")) {
|
||||
ERR_FAIL_COND_V_MSG(status != STATUS_READING_ID, Vector<Vector<String>>(),
|
||||
"Unexpected 'msgstr', was expecting 'msgid' before 'msgstr' while parsing: " + path + ":" + itos(line));
|
||||
l = l.substr(6, l.length()).strip_edges();
|
||||
l = l.substr(6).strip_edges();
|
||||
status = STATUS_READING_STRING;
|
||||
}
|
||||
|
||||
|
|
@ -286,7 +286,7 @@ Vector<Vector<String>> get_extractable_message_list() {
|
|||
|
||||
ERR_FAIL_COND_V_MSG(!l.begins_with("\"") || status == STATUS_NONE, Vector<Vector<String>>(), "Invalid line '" + l + "' while parsing: " + path + ":" + itos(line));
|
||||
|
||||
l = l.substr(1, l.length());
|
||||
l = l.substr(1);
|
||||
// Find final quote, ignoring escaped ones (\").
|
||||
// The escape_next logic is necessary to properly parse things like \\"
|
||||
// where the backslash is the one being escaped, not the quote.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue