summaryrefslogtreecommitdiff
path: root/src/misc2.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2005-04-24 22:04:21 +0000
committerBram Moolenaar <Bram@vim.org>2005-04-24 22:04:21 +0000
commitc91506a0333241681f7564d0d46bb85b793d94b4 (patch)
treedbbfa44758a5dc2d018bf19fa629607d15e44532 /src/misc2.c
parent2a489f5fdd1be0b2abfb5d300e38bad425d4b456 (diff)
downloadvim-git-c91506a0333241681f7564d0d46bb85b793d94b4.tar.gz
updated for version 7.0071
Diffstat (limited to 'src/misc2.c')
-rw-r--r--src/misc2.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/misc2.c b/src/misc2.c
index 0735e2963..a00d3ae49 100644
--- a/src/misc2.c
+++ b/src/misc2.c
@@ -2474,11 +2474,15 @@ get_pseudo_mouse_code(button, is_click, is_drag)
&& is_drag == mouse_table[i].is_drag)
{
#ifdef FEAT_GUI
- /* Trick: a non mappable left click and release has mouse_col < 0.
- * Used for 'mousefocus' in gui_mouse_moved() */
- if (mouse_col < 0)
+ /* Trick: a non mappable left click and release has mouse_col -1
+ * or added MOUSE_COLOFF. Used for 'mousefocus' in
+ * gui_mouse_moved() */
+ if (mouse_col < 0 || mouse_col > MOUSE_COLOFF)
{
- mouse_col = 0;
+ if (mouse_col < 0)
+ mouse_col = 0;
+ else
+ mouse_col -= MOUSE_COLOFF;
if (mouse_table[i].pseudo_code == (int)KE_LEFTMOUSE)
return (int)KE_LEFTMOUSE_NM;
if (mouse_table[i].pseudo_code == (int)KE_LEFTRELEASE)