mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-03-19 05:33:44 -04:00
wayland: unify key- and mouse-binding structs
This commit is contained in:
parent
d04bc6ab10
commit
dcd79065c8
5 changed files with 47 additions and 37 deletions
6
search.c
6
search.c
|
|
@ -838,7 +838,7 @@ search_input(struct seat *seat, struct terminal *term, uint32_t key,
|
|||
const struct key_binding *bind = &it->item;
|
||||
|
||||
/* Match translated symbol */
|
||||
if (bind->sym == sym &&
|
||||
if (bind->k.sym == sym &&
|
||||
bind->mods == (mods & ~consumed)) {
|
||||
|
||||
if (execute_binding(seat, term, bind->action, serial,
|
||||
|
|
@ -854,7 +854,7 @@ search_input(struct seat *seat, struct terminal *term, uint32_t key,
|
|||
|
||||
/* Match untranslated symbols */
|
||||
for (size_t i = 0; i < raw_count; i++) {
|
||||
if (bind->sym == raw_syms[i]) {
|
||||
if (bind->k.sym == raw_syms[i]) {
|
||||
if (execute_binding(seat, term, bind->action, serial,
|
||||
&update_search_result, &redraw))
|
||||
{
|
||||
|
|
@ -865,7 +865,7 @@ search_input(struct seat *seat, struct terminal *term, uint32_t key,
|
|||
}
|
||||
|
||||
/* Match raw key code */
|
||||
tll_foreach(bind->key_codes, code) {
|
||||
tll_foreach(bind->k.key_codes, code) {
|
||||
if (code->item == key) {
|
||||
if (execute_binding(seat, term, bind->action, serial,
|
||||
&update_search_result, &redraw))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue