diff options
| author | Paulb23 | 2018-02-09 17:35:28 +0000 |
|---|---|---|
| committer | Hein-Pieter van Braam | 2018-02-19 22:13:46 +0100 |
| commit | 148e059940bf473de671fcf909620279d3d6876e (patch) | |
| tree | 765f9427ed412cc56062c643a57f26183578874d /editor/plugins/script_editor_plugin.cpp | |
| parent | 7af43c4ca3d72aaab9e1372eb4b7784e0e4c5e6c (diff) | |
| download | godot-148e059940bf473de671fcf909620279d3d6876e.tar.gz godot-148e059940bf473de671fcf909620279d3d6876e.tar.zst godot-148e059940bf473de671fcf909620279d3d6876e.zip | |
Fixed members overview not scrolling to correct line
(cherry picked from commit 4d92c5e1c306b483d30004fe04fbef1ad46f7f7f)
Diffstat (limited to '')
| -rw-r--r-- | editor/plugins/script_editor_plugin.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp index 7b5548e2c..b6658b7b9 100644 --- a/editor/plugins/script_editor_plugin.cpp +++ b/editor/plugins/script_editor_plugin.cpp @@ -1328,11 +1328,12 @@ void ScriptEditor::_members_overview_selected(int p_idx) { if (!se) { return; } - // Go to the member's line and reset the cursor column. We can't just change scroll_position - // directly, since code might be folded. + // Go to the member's line and reset the cursor column. We can't change scroll_position + // directly until we have gone to the line first, since code might be folded. se->goto_line(members_overview->get_item_metadata(p_idx)); Dictionary state = se->get_edit_state(); state["column"] = 0; + state["scroll_position"] = members_overview->get_item_metadata(p_idx); se->set_edit_state(state); } |
