summaryrefslogtreecommitdiff
path: root/editor/plugins
diff options
context:
space:
mode:
authortrollodel <33117082+trollodel@users.noreply.github.com>2022-02-11 17:44:10 +0100
committertrollodel <33117082+trollodel@users.noreply.github.com>2022-02-11 18:45:41 +0100
commite97e894aa02d37ac926a74654845131d9e40289a (patch)
treea57ed005706923a65951c77c877e2c2dabfff1ee /editor/plugins
parentea0337909ce562e4ef0eaed1fc29c2940ebdecaf (diff)
Fix editor compile error when VisualScript is disabled
Diffstat (limited to 'editor/plugins')
-rw-r--r--editor/plugins/script_editor_plugin.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp
index 17de3ba026..97d12af544 100644
--- a/editor/plugins/script_editor_plugin.cpp
+++ b/editor/plugins/script_editor_plugin.cpp
@@ -2265,7 +2265,7 @@ bool ScriptEditor::edit(const RES &p_resource, int p_line, int p_col, bool p_gra
if (use_external_editor &&
(EditorDebuggerNode::get_singleton()->get_dump_stack_script() != p_resource || EditorDebuggerNode::get_singleton()->get_debug_with_external_editor()) &&
p_resource->get_path().is_resource_file() &&
- !Ref<VisualScript>(p_resource).is_valid()) {
+ !p_resource->is_class("VisualScript")) {
String path = EditorSettings::get_singleton()->get("text_editor/external/exec_path");
String flags = EditorSettings::get_singleton()->get("text_editor/external/exec_flags");
@@ -2364,7 +2364,7 @@ bool ScriptEditor::edit(const RES &p_resource, int p_line, int p_col, bool p_gra
se->set_edited_resource(p_resource);
- if (!Ref<VisualScript>(p_resource).is_valid()) {
+ if (!p_resource->is_class("VisualScript")) {
bool highlighter_set = false;
for (int i = 0; i < syntax_highlighters.size(); i++) {
Ref<EditorSyntaxHighlighter> highlighter = syntax_highlighters[i]->_create();