summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorvolzhs <volzhs@gmail.com>2016-10-31 06:20:54 +0900
committervolzhs <volzhs@gmail.com>2016-10-31 06:20:54 +0900
commit707185d9d8a273c1bf2a70dcba707045295427a9 (patch)
tree92443c8e4d07491ef2f7786187730b7ca555dea6
parent2001e0f75ffc23089eba08365e1fbc4fe3b46584 (diff)
downloadredot-engine-707185d9d8a273c1bf2a70dcba707045295427a9.tar.gz
Fix p_index out of size error when closing script
-rw-r--r--tools/editor/plugins/script_editor_plugin.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/editor/plugins/script_editor_plugin.cpp b/tools/editor/plugins/script_editor_plugin.cpp
index b6ce3e89eb..e7170a23f3 100644
--- a/tools/editor/plugins/script_editor_plugin.cpp
+++ b/tools/editor/plugins/script_editor_plugin.cpp
@@ -945,7 +945,7 @@ void ScriptEditor::_menu_option(int p_option) {
}
}
- EditorHelp *help = tab_container->get_child(selected)->cast_to<EditorHelp>();
+ EditorHelp *help = tab_container->get_current_tab_control()->cast_to<EditorHelp>();
if (help) {
switch(p_option) {