aboutsummaryrefslogtreecommitdiff
path: root/editor/plugins/script_editor_plugin.cpp
diff options
context:
space:
mode:
authorRémi Verschelde2017-10-09 15:19:15 +0200
committerGitHub2017-10-09 15:19:15 +0200
commit438e32d6520c4fc37676bfdc2d287178a13c326c (patch)
treefbaacfbc2dc3361ca7f11ec2f7358c6255329594 /editor/plugins/script_editor_plugin.cpp
parentcb7e4aa6d46ec247c7fc41104e4459a062cce77c (diff)
parentb07dfd75eaa3a89aefda9c26e33f91d8eaa80fc8 (diff)
downloadgodot-438e32d6520c4fc37676bfdc2d287178a13c326c.tar.gz
godot-438e32d6520c4fc37676bfdc2d287178a13c326c.tar.zst
godot-438e32d6520c4fc37676bfdc2d287178a13c326c.zip
Merge pull request #11941 from Paulb23/members_selected_scroll_issue_11648
Consistant scroll when using members overview, issue 11648
Diffstat (limited to 'editor/plugins/script_editor_plugin.cpp')
-rw-r--r--editor/plugins/script_editor_plugin.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp
index 5e66488af..477d440f2 100644
--- a/editor/plugins/script_editor_plugin.cpp
+++ b/editor/plugins/script_editor_plugin.cpp
@@ -1278,7 +1278,11 @@ void ScriptEditor::_members_overview_selected(int p_idx) {
if (!se) {
return;
}
- se->goto_line(members_overview->get_item_metadata(p_idx));
+ Dictionary state;
+ state["scroll_position"] = members_overview->get_item_metadata(p_idx);
+ state["column"] = 0;
+ state["row"] = members_overview->get_item_metadata(p_idx);
+ se->set_edit_state(state);
se->ensure_focus();
}