billiob pushed a commit to branch master.

http://git.enlightenment.org/apps/terminology.git/commit/?id=674a87287dab88a24af0d09b99d9f464b1478f4d

commit 674a87287dab88a24af0d09b99d9f464b1478f4d
Author: Boris Faure <[email protected]>
Date:   Tue Mar 5 21:20:50 2019 +0100

    termiointernals: fix reporting mouse move with no button pressed + tests
---
 src/bin/termiointernals.c | 3 +--
 tests/tests.results       | 4 ++--
 2 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/src/bin/termiointernals.c b/src/bin/termiointernals.c
index 93fb722..f82cec1 100644
--- a/src/bin/termiointernals.c
+++ b/src/bin/termiointernals.c
@@ -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)
      {
diff --git a/tests/tests.results b/tests/tests.results
index 41b77a5..2d8e8c2 100644
--- a/tests/tests.results
+++ b/tests/tests.results
@@ -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

-- 


Reply via email to