Use open_search shortcut instead of hard-coded events

This commit is contained in:
kobewi 2026-03-02 18:50:45 +01:00
parent fbb918b699
commit d34bfe89fd
2 changed files with 2 additions and 2 deletions

View file

@ -788,7 +788,7 @@ void EditorAssetLibrary::shortcut_input(const Ref<InputEvent> &p_event) {
const Ref<InputEventKey> key = p_event;
if (key.is_valid() && key->is_pressed()) {
if (key->is_match(InputEventKey::create_reference(KeyModifierMask::CMD_OR_CTRL | Key::F)) && is_visible_in_tree()) {
if (ED_IS_SHORTCUT("editor/open_search", p_event) && is_visible_in_tree()) {
filter->grab_focus();
filter->select_all();
accept_event();

View file

@ -322,7 +322,7 @@ void EditorSettingsDialog::shortcut_input(const Ref<InputEvent> &p_event) {
}
}
if (k->is_match(InputEventKey::create_reference(KeyModifierMask::CMD_OR_CTRL | Key::F))) {
if (ED_IS_SHORTCUT("editor/open_search", p_event)) {
_focus_current_search_box();
handled = true;
}