[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 6cf479931d1 1/3: Don't use selected frame in tty_set_cursor (bug#
From: |
Gerd Moellmann |
Subject: |
master 6cf479931d1 1/3: Don't use selected frame in tty_set_cursor (bug#75056) |
Date: |
Wed, 29 Jan 2025 23:43:18 -0500 (EST) |
branch: master
commit 6cf479931d1adc03661116ef827f77fdc615db22
Author: Gerd Möllmann <gerd@gnu.org>
Commit: Gerd Möllmann <gerd@gnu.org>
Don't use selected frame in tty_set_cursor (bug#75056)
* src/dispnew.c (tty_set_cursor): Add frmae parameter.
(write_matrix): Pass to the updated frame to tty_set_cursor.
---
src/dispnew.c | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/src/dispnew.c b/src/dispnew.c
index d1e731e69f8..6571761b7a9 100644
--- a/src/dispnew.c
+++ b/src/dispnew.c
@@ -5591,10 +5591,8 @@ scrolling_window (struct window *w, int tab_line_p)
************************************************************************/
static void
-tty_set_cursor (void)
+tty_set_cursor (struct frame *f)
{
- struct frame *f = SELECTED_FRAME ();
-
if ((cursor_in_echo_area
/* If we are showing a message instead of the mini-buffer,
show the cursor for the message instead of for the
@@ -5656,7 +5654,7 @@ tty_set_cursor (void)
else
{
/* We have only one cursor on terminal frames. Use it to
- display the cursor of the selected window. */
+ display the cursor of the selected window of the frame. */
struct window *w = XWINDOW (FRAME_SELECTED_WINDOW (f));
if (w->cursor.vpos >= 0
/* The cursor vpos may be temporarily out of bounds
@@ -5709,7 +5707,7 @@ write_matrix (struct frame *f, bool inhibit_id_p,
/* Now just clean up termcap drivers and set cursor, etc. */
if (set_cursor_p)
- tty_set_cursor ();
+ tty_set_cursor (f);
}
/* Do line insertions/deletions on frame F for frame-based redisplay. */