diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2018-03-23 11:28:48 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-03-23 11:28:48 +0100 |
commit | f16652d1a2f94432becea6a8d393a4f99d62fb7b (patch) | |
tree | 62a3bb6584e3a49a96d22b733508b93b7f74d6d5 | |
parent | 699325f9a13f51ca2a592d14c4926942ca9ed901 (diff) | |
parent | 8939f44f6ac5594348e4d671d121680822bd8dc8 (diff) |
Merge pull request #17496 from robfram/fix-f3-change-editor-and-find
Fix pressing `F3` do both changing to script editor AND find next text
-rw-r--r-- | editor/editor_node.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 97b466f75a..99a3602c03 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -190,6 +190,8 @@ void EditorNode::_unhandled_input(const Ref<InputEvent> &p_event) { Ref<InputEventKey> k = p_event; if (k.is_valid() && k->is_pressed() && !k->is_echo() && !gui_base->get_viewport()->gui_has_modal_stack()) { + EditorPlugin *old_editor = editor_plugin_screen; + if (ED_IS_SHORTCUT("editor/next_tab", p_event)) { int next_tab = editor_data.get_edited_scene() + 1; next_tab %= editor_data.get_edited_scene_count(); @@ -225,6 +227,10 @@ void EditorNode::_unhandled_input(const Ref<InputEvent> &p_event) { _bottom_panel_switch(false, i); } } + + if (old_editor != editor_plugin_screen) { + get_tree()->set_input_as_handled(); + } } } |