diff options
author | cdemirer <41021322+cdemirer@users.noreply.github.com> | 2021-12-10 19:52:29 +0800 |
---|---|---|
committer | cdemirer <41021322+cdemirer@users.noreply.github.com> | 2021-12-10 19:56:46 +0800 |
commit | 1cf3f382ba34005d0f21f9459aa23813f29aacfc (patch) | |
tree | d4ba849337be182ee892f3bf1afe0b05fd3e7036 /modules/gdscript | |
parent | 04cc06b28e621c0e522114cabce7d4555735ac8d (diff) |
Fix "Lookup Symbol" on global class members
"Lookup Symbol" on global class members now does switch to the relevant script.
Diffstat (limited to 'modules/gdscript')
-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 34fe2364cb..ec01c19295 100644 --- a/modules/gdscript/gdscript_editor.cpp +++ b/modules/gdscript/gdscript_editor.cpp @@ -2810,6 +2810,7 @@ static Error _lookup_symbol_from_base(const GDScriptParser::DataType &p_base, co r_result.type = ScriptLanguage::LookupResult::RESULT_SCRIPT_LOCATION; r_result.location = base_type.class_type->get_member(p_symbol).get_line(); r_result.class_path = base_type.script_path; + r_result.script = GDScriptCache::get_shallow_script(r_result.class_path); return OK; } base_type = base_type.class_type->base_type; |