aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/syscons
diff options
context:
space:
mode:
authorBruce Evans <bde@FreeBSD.org>2017-08-18 12:45:00 +0000
committerBruce Evans <bde@FreeBSD.org>2017-08-18 12:45:00 +0000
commite4501d816b9e0a75148cff2a08a66f5053bf7b99 (patch)
tree2ebad389f4b671230ede080c7b64eede74490444 /sys/dev/syscons
parenta54b74c7f3bdb25ebdd9b8f107f41e979f8159e8 (diff)
Notes
Diffstat (limited to 'sys/dev/syscons')
-rw-r--r--sys/dev/syscons/scterm-teken.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/sys/dev/syscons/scterm-teken.c b/sys/dev/syscons/scterm-teken.c
index ec38eaf280db..48504757052f 100644
--- a/sys/dev/syscons/scterm-teken.c
+++ b/sys/dev/syscons/scterm-teken.c
@@ -674,6 +674,7 @@ static void
scteken_param(void *arg, int cmd, unsigned int value)
{
scr_stat *scp = arg;
+ int flags;
switch (cmd) {
case TP_SETBORDER:
@@ -682,13 +683,11 @@ scteken_param(void *arg, int cmd, unsigned int value)
sc_set_border(scp, scp->border);
break;
case TP_SHOWCURSOR:
- if (value) {
- sc_change_cursor_shape(scp,
- CONS_RESET_CURSOR|CONS_LOCAL_CURSOR, -1, -1);
- } else {
- sc_change_cursor_shape(scp,
- CONS_HIDDEN_CURSOR|CONS_LOCAL_CURSOR, -1, -1);
- }
+ if (value != 0)
+ flags = scp->curr_curs_attr.flags & ~CONS_HIDDEN_CURSOR;
+ else
+ flags = scp->curr_curs_attr.flags | CONS_HIDDEN_CURSOR;
+ sc_change_cursor_shape(scp, flags | CONS_LOCAL_CURSOR, -1, -1);
break;
case TP_SWITCHVT:
sc_switch_scr(scp->sc, value);