diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2021-05-19 14:22:47 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-19 14:22:47 +0200 |
commit | 365ab8889496b779690d97e25fdc4707641a5d61 (patch) | |
tree | 10a374927f98226cfcac5dd10d3c09e87863c416 | |
parent | 26f0a8648285b70012ec82a31883a0e1d79fad62 (diff) | |
parent | 7b261d1cb7b8025cb999d9e5e11de256e198e128 (diff) |
Merge pull request #48836 from Chaosus/color_autocompletion_fix
Show colored rects for autocompletion of Color constants in functions
-rw-r--r-- | modules/gdscript/gdscript_editor.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/gdscript/gdscript_editor.cpp b/modules/gdscript/gdscript_editor.cpp index 6ae825d2bd..c65f97e637 100644 --- a/modules/gdscript/gdscript_editor.cpp +++ b/modules/gdscript/gdscript_editor.cpp @@ -741,6 +741,7 @@ static void _find_identifiers_in_suite(const GDScriptParser::SuiteNode *p_suite, ScriptCodeCompletionOption option; if (p_suite->locals[i].type == GDScriptParser::SuiteNode::Local::CONSTANT) { option = ScriptCodeCompletionOption(p_suite->locals[i].name, ScriptCodeCompletionOption::KIND_CONSTANT); + option.default_value = p_suite->locals[i].constant->initializer->reduced_value; } else { option = ScriptCodeCompletionOption(p_suite->locals[i].name, ScriptCodeCompletionOption::KIND_VARIABLE); } |