Mercurial > mplayer.hg
diff input/input.c @ 25502:605d4e3e403f
From now on, libmenu does not steal all input keys from input modules.
| author | ulion |
|---|---|
| date | Wed, 26 Dec 2007 13:13:48 +0000 |
| parents | 50a30be5300c |
| children | 54512595b406 |
line wrap: on
line diff
--- a/input/input.c Wed Dec 26 04:15:56 2007 +0000 +++ b/input/input.c Wed Dec 26 13:13:48 2007 +0000 @@ -537,7 +537,7 @@ static mp_cmd_filter_t* cmd_filters = NULL; // Callback to allow the menu filter to grab the incoming keys -void (*mp_input_key_cb)(int code) = NULL; +int (*mp_input_key_cb)(int code) = NULL; static mp_input_fd_t key_fds[MP_MAX_KEY_FD]; static unsigned int num_key_fd = 0; @@ -1070,7 +1070,7 @@ if (code & MP_KEY_DOWN) return NULL; code &= ~(MP_KEY_DOWN|MP_NO_REPEAT_KEY); - mp_input_key_cb(code); + if (mp_input_key_cb(code)) return NULL; }
