Use the standard curs_set() instead of PDC_cursor_*(), which was never

implemented for X. There's some controversy whether leaveok() is really
supposed to turn off the cursor... but if it's OK to leave it anywhere,
then why not leave it off the screen? Also, with this change, turning
off leaveok() will always do curs_set(1), regardless of the previous
state of the cursor.
This commit is contained in:
William McBrine
2006-07-23 18:56:28 +00:00
parent 3f127f3376
commit 9c0ce700b2
2 changed files with 4 additions and 8 deletions

View File

@@ -36,7 +36,7 @@
# undef wmove
#endif
RCSID("$Id: kernel.c,v 1.50 2006/07/23 14:54:17 wmcbrine Exp $");
RCSID("$Id: kernel.c,v 1.51 2006/07/23 18:56:28 wmcbrine Exp $");
RIPPEDOFFLINE linesripped[5];
char linesrippedoff = 0;
@@ -162,8 +162,7 @@ static int PDC_restore_mode(struct cttyset *ctty)
if (ctty->saved.raw_out)
raw();
if (ctty->saved.visible_cursor)
PDC_cursor_on();
curs_set(ctty->saved.visibility);
SP->font = PDC_get_font();
PDC_set_font(ctty->saved.font);

View File

@@ -29,7 +29,7 @@
#undef scrollok
#undef raw_output
RCSID("$Id: outopts.c,v 1.22 2006/07/15 15:38:24 wmcbrine Exp $");
RCSID("$Id: outopts.c,v 1.23 2006/07/23 18:56:28 wmcbrine Exp $");
/*man-start**************************************************************
@@ -161,10 +161,7 @@ int leaveok(WINDOW *win, bool bf)
win->_leaveit = bf;
if (bf)
PDC_cursor_off();
else
PDC_cursor_on();
curs_set(bf);
return OK;
}