You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
Center script line when double clicked on error in debugger
This commit is contained in:
committed by
Dawid Wdowiak
parent
4d6ad16ac4
commit
0f14489ecb
@@ -306,8 +306,11 @@ void ScriptEditor::_goto_script_line(REF p_script, int p_line) {
|
||||
editor->push_item(p_script.ptr());
|
||||
|
||||
ScriptEditorBase *current = _get_current_editor();
|
||||
if (current)
|
||||
if (ScriptTextEditor *script_text_editor = Object::cast_to<ScriptTextEditor>(current)) {
|
||||
script_text_editor->goto_line_centered(p_line);
|
||||
} else if (current) {
|
||||
current->goto_line(p_line, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user