1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-28 10:02:17 +00:00

macosx_events: send all queued events

Seeking feels a little faster or it may be self suggestion. There's really no
reason to just send only one event at a time.
This commit is contained in:
Stefano Pigozzi 2013-06-02 18:21:45 +02:00
parent f0d2120347
commit d67b687530

View File

@ -92,8 +92,9 @@ static int convert_key(unsigned key, unsigned charcode)
void cocoa_check_events(void) void cocoa_check_events(void)
{ {
Application *app = mpv_shared_app(); Application *app = mpv_shared_app();
int key = [app.iqueue pop]; int key;
if (key >= 0) mplayer_put_key(app.keyFIFO, key); while ((key = [app.iqueue pop]) >= 0)
mplayer_put_key(app.keyFIFO, key);
} }
void cocoa_put_key(int keycode) void cocoa_put_key(int keycode)