Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libcurses According to POSIX moving the cursor in curses...
details: https://anonhg.NetBSD.org/src/rev/692bfbc39a73
branches: trunk
changeset: 433665:692bfbc39a73
user: kamil <kamil%NetBSD.org@localhost>
date: Wed Sep 26 18:51:45 2018 +0000
description:
According to POSIX moving the cursor in curses(3) touches the window
Mark the old and new lines as dirty, so they will be refreshed upon next
call to getch(3)-like routine.
This also matches the ncurses behavior.
Reviewed by <roy>
diffstat:
lib/libcurses/move.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diffs (29 lines):
diff -r c38991115344 -r 692bfbc39a73 lib/libcurses/move.c
--- a/lib/libcurses/move.c Wed Sep 26 18:32:51 2018 +0000
+++ b/lib/libcurses/move.c Wed Sep 26 18:51:45 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: move.c,v 1.18 2017/01/06 13:53:18 roy Exp $ */
+/* $NetBSD: move.c,v 1.19 2018/09/26 18:51:45 kamil Exp $ */
/*
* Copyright (c) 1981, 1993, 1994
@@ -34,7 +34,7 @@
#if 0
static char sccsid[] = "@(#)move.c 8.2 (Berkeley) 5/4/94";
#else
-__RCSID("$NetBSD: move.c,v 1.18 2017/01/06 13:53:18 roy Exp $");
+__RCSID("$NetBSD: move.c,v 1.19 2018/09/26 18:51:45 kamil Exp $");
#endif
#endif /* not lint */
@@ -72,8 +72,10 @@
return ERR;
win->curx = x;
win->alines[win->cury]->flags &= ~__ISPASTEOL;
+ win->alines[win->cury]->flags |= __ISDIRTY;
win->cury = y;
win->alines[y]->flags &= ~__ISPASTEOL;
+ win->alines[y]->flags |= __ISDIRTY;
return OK;
}
Home |
Main Index |
Thread Index |
Old Index