diff options
| author | Glenn Morris | 2021-10-21 08:02:57 -0700 |
|---|---|---|
| committer | Glenn Morris | 2021-10-21 08:02:57 -0700 |
| commit | bd7b5f72a96a3e80a7c06625e058ead88ee832cf (patch) | |
| tree | 73c7b4937da21c843721bfb9e6b85c0d43b2db9e /src | |
| parent | a4c232effce74028e9a904e15c9616fba33a4143 (diff) | |
| parent | 0545c70c168d2cc3f4fa794312b23f2616f67327 (diff) | |
| download | emacs-bd7b5f72a96a3e80a7c06625e058ead88ee832cf.tar.gz emacs-bd7b5f72a96a3e80a7c06625e058ead88ee832cf.zip | |
Merge from origin/emacs-28
0545c70c16 (origin/emacs-28) ; * src/keyboard.c (readable_events): Ad...
805ed8d318 Fix todo-mode AOT test failures (bug#51308)
8f42ff31f6 Fix hi-lock AOT test failures (bug#51308)
8002fcd4b9 Fix socks test
4540130312 ; Fix typo
59df93e2dd * lisp/help.el (help--analyze-key): Add new arg BUFFER (bu...
cb8b12b56d Improve docstrings and NEWS item of 'repeat-mode'
06fe499614 * lisp/tab-bar.el (tab-bar-menu-bar): New command (bug#512...
8358da9c4c Display a tab bar item as sunken when appropriate
29fdc65860 Fix tab bar item highlight when a mouse click is dropped
7236592668 Refer to mouse-highlight from make-pointer-invisible docst...
cf4394a397 * etc/PROBLEMS: Add hex codepoint for NO-BREAK SPACE
2d647e88fa Describe how to debug fontconfig issues
c916040921 Adapt Tramp tests
1bb14f93f1 Convert ANSI color definitions in themes to use faces (e.g...
8e7cd29712 Revert "Revert back to using ESC as viper-ESC-key again"
91d71b38a3 Fix inset rectangle corners when sides aren't drawn (bug#5...
5c1a575ef4 Don't use color escape sequences in vc-git-expanded-log-entry
d7f595cc89 Code cleanup in tramp-tests.el
548a5db611 ; etc/NEWS fix wording
# Conflicts:
# etc/NEWS
Diffstat (limited to 'src')
| -rw-r--r-- | src/frame.c | 5 | ||||
| -rw-r--r-- | src/keyboard.c | 2 | ||||
| -rw-r--r-- | src/nsterm.m | 7 | ||||
| -rw-r--r-- | src/xdisp.c | 17 |
4 files changed, 27 insertions, 4 deletions
diff --git a/src/frame.c b/src/frame.c index f95566818af..2b1cb452efd 100644 --- a/src/frame.c +++ b/src/frame.c | |||
| @@ -6238,7 +6238,10 @@ when the mouse is over clickable text. */); | |||
| 6238 | 6238 | ||
| 6239 | DEFVAR_LISP ("make-pointer-invisible", Vmake_pointer_invisible, | 6239 | DEFVAR_LISP ("make-pointer-invisible", Vmake_pointer_invisible, |
| 6240 | doc: /* If non-nil, make mouse pointer invisible while typing. | 6240 | doc: /* If non-nil, make mouse pointer invisible while typing. |
| 6241 | The pointer becomes visible again when the mouse is moved. */); | 6241 | The pointer becomes visible again when the mouse is moved. |
| 6242 | |||
| 6243 | When using this, you might also want to disable highlighting of | ||
| 6244 | clickable text. See `mouse-highlight'. */); | ||
| 6242 | Vmake_pointer_invisible = Qt; | 6245 | Vmake_pointer_invisible = Qt; |
| 6243 | 6246 | ||
| 6244 | DEFVAR_LISP ("move-frame-functions", Vmove_frame_functions, | 6247 | DEFVAR_LISP ("move-frame-functions", Vmove_frame_functions, |
diff --git a/src/keyboard.c b/src/keyboard.c index be9fad3ac3b..6e8a1e3657a 100644 --- a/src/keyboard.c +++ b/src/keyboard.c | |||
| @@ -3450,6 +3450,8 @@ readable_events (int flags) | |||
| 3450 | READABLE_EVENTS_FILTER_EVENTS is set, report it as empty. */ | 3450 | READABLE_EVENTS_FILTER_EVENTS is set, report it as empty. */ |
| 3451 | if (kbd_fetch_ptr != kbd_store_ptr) | 3451 | if (kbd_fetch_ptr != kbd_store_ptr) |
| 3452 | { | 3452 | { |
| 3453 | /* See https://lists.gnu.org/r/emacs-devel/2005-05/msg00297.html | ||
| 3454 | for why we treat toolkit scroll-bar events specially here. */ | ||
| 3453 | if (flags & (READABLE_EVENTS_FILTER_EVENTS | 3455 | if (flags & (READABLE_EVENTS_FILTER_EVENTS |
| 3454 | #ifdef USE_TOOLKIT_SCROLL_BARS | 3456 | #ifdef USE_TOOLKIT_SCROLL_BARS |
| 3455 | | READABLE_EVENTS_IGNORE_SQUEEZABLES | 3457 | | READABLE_EVENTS_IGNORE_SQUEEZABLES |
diff --git a/src/nsterm.m b/src/nsterm.m index c6f80f80350..aa29c13eb22 100644 --- a/src/nsterm.m +++ b/src/nsterm.m | |||
| @@ -3512,7 +3512,12 @@ ns_draw_relief (NSRect outer, int hthickness, int vthickness, char raised_p, | |||
| 3512 | } | 3512 | } |
| 3513 | 3513 | ||
| 3514 | /* Calculate the inner rectangle. */ | 3514 | /* Calculate the inner rectangle. */ |
| 3515 | inner = NSInsetRect (outer, hthickness, vthickness); | 3515 | inner = NSMakeRect (NSMinX (outer) + (left_p ? hthickness : 0), |
| 3516 | NSMinY (outer) + (top_p ? vthickness : 0), | ||
| 3517 | NSWidth (outer) - (left_p ? hthickness : 0) | ||
| 3518 | - (right_p ? hthickness : 0), | ||
| 3519 | NSHeight (outer) - (top_p ? vthickness : 0) | ||
| 3520 | - (bottom_p ? vthickness : 0)); | ||
| 3516 | 3521 | ||
| 3517 | [(raised_p ? lightCol : darkCol) set]; | 3522 | [(raised_p ? lightCol : darkCol) set]; |
| 3518 | 3523 | ||
diff --git a/src/xdisp.c b/src/xdisp.c index 738f22abedd..8eb5b2e4bd4 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -13867,12 +13867,17 @@ note_tab_bar_highlight (struct frame *f, int x, int y) | |||
| 13867 | 13867 | ||
| 13868 | bool mouse_down_p = false; | 13868 | bool mouse_down_p = false; |
| 13869 | #ifndef HAVE_NS | 13869 | #ifndef HAVE_NS |
| 13870 | /* Mouse is down, but on different tab-bar item? */ | 13870 | /* Mouse is down, but on different tab-bar item? Or alternatively, |
| 13871 | the mouse might've been pressed somewhere we don't know about, | ||
| 13872 | and then have moved onto the tab bar. In this case, | ||
| 13873 | last_tab_bar_item is -1, so we DTRT and behave like other | ||
| 13874 | programs by displaying the item as sunken. */ | ||
| 13871 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); | 13875 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); |
| 13872 | mouse_down_p = (gui_mouse_grabbed (dpyinfo) | 13876 | mouse_down_p = (gui_mouse_grabbed (dpyinfo) |
| 13873 | && f == dpyinfo->last_mouse_frame); | 13877 | && f == dpyinfo->last_mouse_frame); |
| 13874 | 13878 | ||
| 13875 | if (mouse_down_p && f->last_tab_bar_item != prop_idx) | 13879 | if (mouse_down_p && f->last_tab_bar_item != prop_idx |
| 13880 | && f->last_tab_bar_item != -1) | ||
| 13876 | return; | 13881 | return; |
| 13877 | #endif | 13882 | #endif |
| 13878 | draw = mouse_down_p ? DRAW_IMAGE_SUNKEN : DRAW_IMAGE_RAISED; | 13883 | draw = mouse_down_p ? DRAW_IMAGE_SUNKEN : DRAW_IMAGE_RAISED; |
| @@ -33788,6 +33793,14 @@ note_mouse_highlight (struct frame *f, int x, int y) | |||
| 33788 | else | 33793 | else |
| 33789 | return; | 33794 | return; |
| 33790 | } | 33795 | } |
| 33796 | else | ||
| 33797 | { | ||
| 33798 | /* The mouse might have pressed into the tab bar, but might | ||
| 33799 | also have been released outside the tab bar, so | ||
| 33800 | f->last_tab_bar_item must be reset, in order to make sure the | ||
| 33801 | item can be still highlighted again in the future. */ | ||
| 33802 | f->last_tab_bar_item = -1; | ||
| 33803 | } | ||
| 33791 | #endif | 33804 | #endif |
| 33792 | 33805 | ||
| 33793 | #if defined (HAVE_WINDOW_SYSTEM) && ! defined (HAVE_EXT_TOOL_BAR) | 33806 | #if defined (HAVE_WINDOW_SYSTEM) && ! defined (HAVE_EXT_TOOL_BAR) |