summaryrefslogtreecommitdiffstats
path: root/modules/gdscript/register_types.cpp
diff options
context:
space:
mode:
authorSkyJJ <jjchai01@hotmail.com>2020-06-23 13:48:59 +0200
committerSkyJJ <jjchai01@hotmail.com>2020-07-02 14:47:35 +0200
commitefb460942536fcd35aa50fc6dbeb6aeea6917642 (patch)
tree1298aba304d8bd128362ed5ce3cfbe33ff5953de /modules/gdscript/register_types.cpp
parent1db29d0101816825af6641bbfbbc3cef6d394dc2 (diff)
downloadredot-engine-efb460942536fcd35aa50fc6dbeb6aeea6917642.tar.gz
Add translation parser plugin support
Diffstat (limited to 'modules/gdscript/register_types.cpp')
-rw-r--r--modules/gdscript/register_types.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/gdscript/register_types.cpp b/modules/gdscript/register_types.cpp
index 0625123530..53e760ffa7 100644
--- a/modules/gdscript/register_types.cpp
+++ b/modules/gdscript/register_types.cpp
@@ -46,7 +46,9 @@ Ref<ResourceFormatSaverGDScript> resource_saver_gd;
#include "editor/editor_export.h"
#include "editor/editor_node.h"
#include "editor/editor_settings.h"
+#include "editor/editor_translation_parser.h"
#include "editor/gdscript_highlighter.h"
+#include "editor/gdscript_translation_parser_plugin.h"
#ifndef GDSCRIPT_NO_LSP
#include "core/engine.h"
@@ -164,6 +166,10 @@ void register_gdscript_types() {
#ifdef TOOLS_ENABLED
ScriptEditor::register_create_syntax_highlighter_function(GDScriptSyntaxHighlighter::create);
EditorNode::add_init_callback(_editor_init);
+
+ Ref<GDScriptEditorTranslationParserPlugin> gdscript_translation_parser_plugin;
+ gdscript_translation_parser_plugin.instance();
+ EditorTranslationParser::get_singleton()->add_parser(gdscript_translation_parser_plugin, EditorTranslationParser::STANDARD);
#endif // TOOLS_ENABLED
}