Revert "player/command: don't send mouse move event on mouse leave request"
There is no reason to do this, since VOs do report mouse position when
outside of window in some cases.
This reverts commit 3ff7b04790.
This commit is contained in:
1 parent
891273055f
commit
bceb1eeaf4
1 file changed
+3
-6
+3
-6
@@ -7052,8 +7052,7 @@ static void cmd_mouse(void *p)
|
||||
if (button == -1) {// no button
|
||||
if (pre_key)
|
||||
mp_input_put_key_artificial(mpctx->input, pre_key, 1);
|
||||
if (pre_key != MP_KEY_MOUSE_LEAVE)
|
||||
mp_input_set_mouse_pos_artificial(mpctx->input, x, y);
|
||||
mp_input_set_mouse_pos_artificial(mpctx->input, x, y);
|
||||
return;
|
||||
}
|
||||
if (button < 0 || button >= MP_KEY_MOUSE_BTN_COUNT) {// invalid button
|
||||
@@ -7071,10 +7070,8 @@ static void cmd_mouse(void *p)
|
||||
button += dbc ? MP_MBTN_DBL_BASE : MP_MBTN_BASE;
|
||||
if (pre_key)
|
||||
mp_input_put_key_artificial(mpctx->input, pre_key, 1);
|
||||
if (pre_key != MP_KEY_MOUSE_LEAVE) {
|
||||
mp_input_set_mouse_pos_artificial(mpctx->input, x, y);
|
||||
mp_input_put_key_artificial(mpctx->input, button, 1);
|
||||
}
|
||||
mp_input_set_mouse_pos_artificial(mpctx->input, x, y);
|
||||
mp_input_put_key_artificial(mpctx->input, button, 1);
|
||||
}
|
||||
|
||||
static void cmd_key(void *p)
|
||||
|
||||
Reference in new issue
Block a user