summaryrefslogtreecommitdiff
path: root/src/xdisp.c
diff options
context:
space:
mode:
authorMartin Rudalics <rudalics@gmx.at>2021-07-05 10:53:39 +0200
committerMartin Rudalics <rudalics@gmx.at>2021-07-05 10:53:39 +0200
commitf7dcad927521279cf750cbf25988671f7198bc4c (patch)
treefe9224dfd873b75ef757d01335dbdb613d88f17d /src/xdisp.c
parentddf6226350934a9e9ffe436d46141c752eb440b7 (diff)
downloademacs-f7dcad927521279cf750cbf25988671f7198bc4c.tar.gz
emacs-f7dcad927521279cf750cbf25988671f7198bc4c.tar.bz2
emacs-f7dcad927521279cf750cbf25988671f7198bc4c.zip
Show hand cursor when dragging frame (Bug#49247)
* src/xdisp.c (note_mode_line_or_margin_highlight): Show hand cursor when dragging frame with mode, tab or header line. (syms_of_xdisp): Define Qdrag_with_mode_line, Qdrag_with_header_line and Qdrag_with_tab_line.
Diffstat (limited to 'src/xdisp.c')
-rw-r--r--src/xdisp.c20
1 files changed, 19 insertions, 1 deletions
diff --git a/src/xdisp.c b/src/xdisp.c
index c30084cc8b5..8f4dfa5430c 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -33236,7 +33236,8 @@ note_mode_line_or_margin_highlight (Lisp_Object window, int x, int y,
of the mode line without any text (e.g. past the right edge of
the mode line text), use that windows's mode line help echo if it
has been set. */
- if (STRINGP (string) || area == ON_MODE_LINE)
+ if (STRINGP (string) || area == ON_MODE_LINE || area == ON_HEADER_LINE
+ || area == ON_TAB_LINE)
{
/* Arrange to display the help by setting the global variables
help_echo_string, help_echo_object, and help_echo_pos. */
@@ -33293,6 +33294,19 @@ note_mode_line_or_margin_highlight (Lisp_Object window, int x, int y,
}
else if (draggable && area == ON_MODE_LINE)
cursor = FRAME_OUTPUT_DATA (f)->vertical_drag_cursor;
+ else if ((area == ON_MODE_LINE
+ && WINDOW_BOTTOMMOST_P (w)
+ && !FRAME_HAS_MINIBUF_P (f)
+ && !NILP (Fframe_parameter
+ (w->frame, Qdrag_with_mode_line)))
+ || (((area == ON_HEADER_LINE
+ && !NILP (Fframe_parameter
+ (w->frame, Qdrag_with_header_line)))
+ || (area == ON_TAB_LINE
+ && !NILP (Fframe_parameter
+ (w->frame, Qdrag_with_tab_line))))
+ && WINDOW_TOPMOST_P (w)))
+ cursor = FRAME_OUTPUT_DATA (f)->hand_cursor;
else
cursor = FRAME_OUTPUT_DATA (f)->nontext_cursor;
}
@@ -34882,6 +34896,10 @@ be let-bound around code that needs to disable messages temporarily. */);
DEFSYM (Qdragging, "dragging");
DEFSYM (Qdropping, "dropping");
+ DEFSYM (Qdrag_with_mode_line, "drag-with-mode-line");
+ DEFSYM (Qdrag_with_header_line, "drag-with-header-line");
+ DEFSYM (Qdrag_with_tab_line, "drag-with-tab-line");
+
DEFSYM (Qinhibit_free_realized_faces, "inhibit-free-realized-faces");
list_of_error = list1 (list2 (Qerror, Qvoid_variable));