diff options
author | Po Lu <luangruo@yahoo.com> | 2022-07-18 12:42:23 +0800 |
---|---|---|
committer | Po Lu <luangruo@yahoo.com> | 2022-07-18 12:42:55 +0800 |
commit | 5480d02cc56bb787f6cd1f81bb1626793f6e1247 (patch) | |
tree | c15b5ca8b4cf73ab32e7df8b37b4e4cd8ceee699 | |
parent | ab5468e1a01ede3d571765ab491ce2c933ace70f (diff) | |
download | emacs-5480d02cc56bb787f6cd1f81bb1626793f6e1247.tar.gz |
Preserve echo area message when running DND mouse movement function
* lisp/term/x-win.el (x-dnd-movement): Stop redisplaying here.
* src/xterm.c (x_dnd_begin_drag_and_drop): Redisplay with the
echo area preserved.
-rw-r--r-- | lisp/term/x-win.el | 3 | ||||
-rw-r--r-- | src/xterm.c | 5 |
2 files changed, 6 insertions, 2 deletions
diff --git a/lisp/term/x-win.el b/lisp/term/x-win.el index 3a0bd65f29c..55fe11a097c 100644 --- a/lisp/term/x-win.el +++ b/lisp/term/x-win.el @@ -1568,8 +1568,7 @@ frames on all displays." (defun x-dnd-movement (_frame position) "Handle movement to POSITION during drag-and-drop." - (dnd-handle-movement position) - (redisplay)) + (dnd-handle-movement position)) (defun x-device-class (name) "Return the device class of NAME. diff --git a/src/xterm.c b/src/xterm.c index 53c640ca6c2..0436d3c00c0 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -11779,6 +11779,11 @@ x_dnd_begin_drag_and_drop (struct frame *f, Time time, Atom xaction, Fposn_at_x_y (x, y, frame_object, Qnil)); x_dnd_unwind_flag = false; unbind_to (ref, Qnil); + + /* Redisplay this way to preserve the echo area. + Otherwise, the contents will abruptly disappear + when the mouse moves over a frame. */ + redisplay_preserve_echo_area (33); } } |