termiointernals: fix reporting mouse move with no button pressed + tests

This commit is contained in:
Boris Faure 2019-03-05 21:20:50 +01:00
parent 77ba576234
commit 674a87287d
2 changed files with 3 additions and 4 deletions

View File

@ -1760,8 +1760,7 @@ _rep_mouse_move(Termio *sd, int cx, int cy, Termio_Modifiers modifiers)
return EINA_FALSE;
if (modifiers.alt)
meta = 8;
btn = sd->mouse.button - 1;
btn = (sd->mouse.button > 0) ? sd->mouse.button - 1 : 3;
switch (sd->pty->mouse_ext)
{

View File

@ -105,11 +105,11 @@ resize_window_no_content_change.sh 28d45fe49c686c8c98631cce8e4bd368
mouse_reporting_mode_x10_ext_none.sh b56ef7d0e2cc236e31ff2e149528833b
mouse_reporting_mode_normal_ext_none.sh f93ea2ac6acb8d36cac9e37e06ed9bd8
mouse_reporting_mode_mouse_move_pressed_ext_none.sh 517ee04a059dfd9400fdcd633a7a5d5c
mouse_reporting_mode_all_ext_none.sh 3f0e5432b989c044687627e1ee134571
mouse_reporting_mode_all_ext_none.sh 0e46ab28bca4e16204cd54552227e826
mouse_reporting_mode_x10_ext_utf8.sh c503d835cde7b0d147ae7a61e1b44fd1
mouse_reporting_mode_normal_ext_utf8.sh 2f615fa516bbf2ad4233f522a0f007d9
mouse_reporting_mode_mouse_move_pressed_ext_utf8.sh dd7265c391b830e5efa2496bfd7f6d36
mouse_reporting_mode_all_ext_utf8.sh 21fd1fe0a68f7695d0a6b3c519131808
mouse_reporting_mode_all_ext_utf8.sh 459fa508d377e8eebf120f15a3a23440
mouse_reporting_mode_x10_ext_sgr.sh 82517b141a920771f5324bb1648c4cd2
mouse_reporting_mode_normal_ext_sgr.sh 6599bde2c0edfc462c85762fd9d7ce34
mouse_reporting_mode_mouse_move_pressed_ext_sgr.sh 6e0ea58d3be307682d9c98be7c1e13cc