Commit 4a2213af authored by Seungha Yang's avatar Seungha Yang

gst-play: Handle KeyDown event instead of KeyUp on Win32 keyboard handler

To handle long press case, KeyDown input should be handled instead of KeyUp.
Note that OS will take care of the sensitivity of KeyDown event, so we can safely
assume one KeyDown as one input. That will not break user experience.
parent e0f27b48
Pipeline #66936 passed with stages
in 54 minutes and 48 seconds
......@@ -154,7 +154,7 @@ gst_play_kb_source_cb (Win32KeyHandler * handler)
if (PeekConsoleInput (h_input, &buffer, 1, &n) && n == 1) {
ReadConsoleInput (h_input, &buffer, 1, &n);
if (buffer.EventType == KEY_EVENT && !buffer.Event.KeyEvent.bKeyDown) {
if (buffer.EventType == KEY_EVENT && buffer.Event.KeyEvent.bKeyDown) {
gchar key_val[2] = { 0 };
switch (buffer.Event.KeyEvent.wVirtualKeyCode) {
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment