#include "sysdep.h"
#include "config.h"
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
# ifdef OK
# undef OK
# endif
-#include CURSES_INC
+#include <curses.h>
#endif
#define MAXSETUP 19
int direction;
void cleanup(int exitcode) {
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
if (setup_type == UI_CURSES) {
clear();
refresh();
}
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
void getlin(int yp, int xp, char *string, int lim) /* Gets a line from the terminal */
/* Where on the screen to start */
/* Pointer to string buffer */
void hit_any_key(void) {
char junk[5];
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
if (setup_type == UI_CURSES) {
mvprintw(20, 0, "Press any key to continue... ");
refresh();
sprintf(buf, "dialog --yesno \"%s\" 7 80", question);
answer = ( (system(buf)==0) ? 1 : 0);
break;
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
case UI_CURSES:
do {
clear();
title, msgtext);
system(buf);
break;
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
case UI_CURSES:
clear();
move(1, 20);
}
break;
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
case UI_CURSES:
if (curr==0) {
clear();
str[strlen(str)-1]=0;
}
break;
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
case UI_CURSES:
clear();
move(1, ((80-strlen(setup_titles[msgpos]))/2) );
*/
int discover_ui(void) {
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
return UI_CURSES;
#endif
setup_type = discover_ui();
}
-#ifdef CURSES_INC
+#ifdef HAVE_CURSES_H
if (setup_type == UI_CURSES) {
initscr();
raw();