diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2019-03-16 11:06:34 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-16 11:06:34 -0700 |
commit | 8965ff90ca0e1ddeeb17e87c72701ecda6edd593 (patch) | |
tree | 15e55ed71afff15c8481a6c610a4415409b389e7 /editor | |
parent | ffd115dd6f04abfdabc0d3ed9270b9890815d171 (diff) | |
parent | e8fe174616b075db8a34b06dd1a19e93a9f7c0ad (diff) |
Merge pull request #26919 from jabcross/master
Implement source lookup for class_name defined classes
Diffstat (limited to 'editor')
-rw-r--r-- | editor/plugins/script_text_editor.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp index e95b1356bf..554e12f9fd 100644 --- a/editor/plugins/script_text_editor.cpp +++ b/editor/plugins/script_text_editor.cpp @@ -620,7 +620,9 @@ void ScriptTextEditor::_lookup_symbol(const String &p_symbol, int p_row, int p_c } ScriptLanguage::LookupResult result; - if (p_symbol.is_resource_file()) { + if (ScriptServer::is_global_class(p_symbol)) { + EditorNode::get_singleton()->load_resource(ScriptServer::get_global_class_path(p_symbol)); + } else if (p_symbol.is_resource_file()) { List<String> scene_extensions; ResourceLoader::get_recognized_extensions_for_type("PackedScene", &scene_extensions); |