/****************************************************************************
- * 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.75 2013/11/16 19:25:39 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 (win) {
SCREEN *sp = _nc_screen_of(win);
- if (sp != 0 && IsTermInfo(sp)) {
+ if (sp != 0
+#ifdef USE_TERM_DRIVER
+ && IsTermInfo(sp)
+#endif
+ ) {
sp->_nc_sp_idlok =
win->_idlok = (flag && (NCURSES_SP_NAME(has_il) (NCURSES_SP_ARG)
|| change_scroll_region));
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