[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
emacs-28 29fdc65 1/2: Fix tab bar item highlight when a mouse click is d
From: |
Juri Linkov |
Subject: |
emacs-28 29fdc65 1/2: Fix tab bar item highlight when a mouse click is dropped |
Date: |
Wed, 20 Oct 2021 12:42:56 -0400 (EDT) |
branch: emacs-28
commit 29fdc65860e95a6e1c74147a3d310878080f6118
Author: Po Lu <luangruo@yahoo.com>
Commit: Juri Linkov <juri@linkov.net>
Fix tab bar item highlight when a mouse click is dropped
* src/xdisp.c (note_mouse_highlight): Clear last_tab_bar_item if the
movement wasn't made on top of the tab bar.
---
src/xdisp.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/xdisp.c b/src/xdisp.c
index 67946a5..97ba672 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -33652,6 +33652,14 @@ note_mouse_highlight (struct frame *f, int x, int y)
else
return;
}
+ else
+ {
+ /* The mouse might have pressed into the tab bar, but might
+ also have been released outside the tab bar, so
+ f->last_tab_bar_item must be reset, in order to make sure the
+ item can be still highlighted again in the future. */
+ f->last_tab_bar_item = -1;
+ }
#endif
#if defined (HAVE_WINDOW_SYSTEM) && ! defined (HAVE_EXT_TOOL_BAR)