diff src/os_unix.c @ 16523:a72ad8a8b249 v8.1.1265

patch 8.1.1265: when GPM mouse support is enabled double clicks do not work commit https://github.com/vim/vim/commit/bedf091a951bdcd5f9f13839c0aaf2e395a635f6 Author: Bram Moolenaar <Bram@vim.org> Date: Sat May 4 16:58:45 2019 +0200 patch 8.1.1265: when GPM mouse support is enabled double clicks do not work Problem: When GPM mouse support is enabled double clicks in xterm do not work. Solution: Use KS_GPM_MOUSE for GPM mouse events.
author Bram Moolenaar <Bram@vim.org>
date Sat, 04 May 2019 17:00:07 +0200
parents 4182f74e2965
children 5412fcd03ecb
line wrap: on
line diff
--- a/src/os_unix.c
+++ b/src/os_unix.c
@@ -3794,7 +3794,10 @@ check_mouse_termcode(void)
 	    && !gui.in_use
 #  endif
 	    )
-	set_mouse_termcode(KS_MOUSE, (char_u *)IF_EB("\033MG", ESC_STR "MG"));
+	set_mouse_termcode(KS_GPM_MOUSE,
+				      (char_u *)IF_EB("\033MG", ESC_STR "MG"));
+    else
+	del_mouse_termcode(KS_GPM_MOUSE);
 # endif
 
 # ifdef FEAT_SYSMOUSE
@@ -7065,7 +7068,8 @@ gpm_close(void)
 	Gpm_Close();
 }
 
-/* Reads gpm event and adds special keys to input buf. Returns length of
+/*
+ * Reads gpm event and adds special keys to input buf. Returns length of
  * generated key sequence.
  * This function is styled after gui_send_mouse_event().
  */