diff options
Diffstat (limited to 'mp_fifo.c')
-rw-r--r-- | mp_fifo.c | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -67,3 +67,13 @@ void mplayer_put_key(struct mp_fifo *fifo, int code) fifo->last_down_time = now; } } + +void mplayer_put_key_utf8(struct mp_fifo *fifo, int mods, struct bstr t) +{ + while (t.len) { + int code = bstr_decode_utf8(t, &t); + if (code < 0) + break; + mplayer_put_key(fifo, code | mods); + } +} |