Commit b04021eb authored by Eli Zaretskii's avatar Eli Zaretskii
Browse files

(IT_display_cursor): Write "CURSOR ON/OFF" to termscript only when

the state changes.
parent 1b912a3b
2008-08-30 Eli Zaretskii <eliz@gnu.org>
 
* msdos.c (IT_display_cursor): Write "CURSOR ON/OFF" to termscript
only when the state changes.
* w16select.c (Fw16_set_clipboard_data): Don't encode text if
clipboard is unavailable. Set dst to NULL if it doesn't point to
malloc'ed data.
......
......@@ -1728,17 +1728,19 @@ IT_display_cursor (int on)
{
struct tty_display_info *tty = CURTTY ();
if (tty->termscript)
fprintf (tty->termscript, "\nCURSOR %s", on ? "ON" : "OFF");
if (on && cursor_cleared)
{
ScreenSetCursor (current_pos_Y, current_pos_X);
cursor_cleared = 0;
if (tty->termscript)
fprintf (tty->termscript, "\nCURSOR ON");
}
else if (!on && !cursor_cleared)
{
ScreenSetCursor (-1, -1);
cursor_cleared = 1;
if (tty->termscript)
fprintf (tty->termscript, "\nCURSOR OFF");
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment