summaryrefslogtreecommitdiff
path: root/modules/visual_script/visual_script_editor.cpp
diff options
context:
space:
mode:
authorPaulb23 <p_batty@hotmail.co.uk>2020-07-26 15:57:23 +0100
committerPaulb23 <p_batty@hotmail.co.uk>2020-09-10 20:35:28 +0100
commit4d7df24d46f931839247a9886c485ed244d1c8ee (patch)
tree9f14dc892815039d3c2ec7984913dbb531d0ca8f /modules/visual_script/visual_script_editor.cpp
parent907f9f2a8444be195d489ae614f88018a10cf6ce (diff)
Add main_gutter (breakpoints, bookmarks, execution lines) to code_edit
Diffstat (limited to 'modules/visual_script/visual_script_editor.cpp')
-rw-r--r--modules/visual_script/visual_script_editor.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/modules/visual_script/visual_script_editor.cpp b/modules/visual_script/visual_script_editor.cpp
index 5581ea9318..7c3af016b9 100644
--- a/modules/visual_script/visual_script_editor.cpp
+++ b/modules/visual_script/visual_script_editor.cpp
@@ -2682,7 +2682,8 @@ void VisualScriptEditor::reload(bool p_soft) {
_update_graph();
}
-void VisualScriptEditor::get_breakpoints(List<int> *p_breakpoints) {
+Array VisualScriptEditor::get_breakpoints() {
+ Array breakpoints;
List<StringName> functions;
script->get_function_list(&functions);
for (List<StringName>::Element *E = functions.front(); E; E = E->next()) {
@@ -2691,10 +2692,11 @@ void VisualScriptEditor::get_breakpoints(List<int> *p_breakpoints) {
for (List<int>::Element *F = nodes.front(); F; F = F->next()) {
Ref<VisualScriptNode> vsn = script->get_node(E->get(), F->get());
if (vsn->is_breakpoint()) {
- p_breakpoints->push_back(F->get() - 1); //subtract 1 because breakpoints in text start from zero
+ breakpoints.push_back(F->get() - 1); //subtract 1 because breakpoints in text start from zero
}
}
}
+ return breakpoints;
}
void VisualScriptEditor::add_callback(const String &p_function, PackedStringArray p_args) {