/****************************************************************************
- * Copyright (c) 1998-2011,2013 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2013,2014 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
#define CUR SP_TERMTYPE
#endif
-MODULE_ID("$Id: lib_options.c,v 1.76 2013/12/14 22:23:58 tom Exp $")
+MODULE_ID("$Id: lib_options.c,v 1.78 2014/09/27 21:55:24 tom Exp $")
NCURSES_EXPORT(int)
idlok(WINDOW *win, bool flag)
if (SP_PARM != 0 && vis >= 0 && vis <= 2) {
int cursor = SP_PARM->_cursor;
- bool bBuiltIn = !IsTermInfo(SP_PARM);
if (vis == cursor) {
code = cursor;
} else {
- if (!bBuiltIn) {
+#ifdef USE_TERM_DRIVER
+ code = CallDriver_1(SP_PARM, td_cursorSet, vis);
+#else
+ if (IsTermInfo(SP_PARM)) {
switch (vis) {
case 2:
code = NCURSES_PUTP2_FLUSH("cursor_visible",
cursor_invisible);
break;
}
- } else
+ } else {
code = ERR;
+ }
+#endif
if (code != ERR)
code = (cursor == -1 ? 1 : cursor);
SP_PARM->_cursor = vis;
#endif
{
#ifdef USE_TERM_DRIVER
- rc = CallDriver_1(sp, kpad, flag);
+ rc = CallDriver_1(sp, td_kpad, flag);
if (rc == OK)
sp->_keypad_on = flag;
#else