Przeglądaj źródła

* configure.ac src/graphics:

+ Check for resize_term and resizeterm in -lncurses.
tags/v0.99.beta14
Sam Hocevar sam 22 lat temu
rodzic
commit
e80006de20
3 zmienionych plików z 12 dodań i 1 usunięć
  1. +6
    -1
      configure.ac
  2. +2
    -0
      msvc/config.h
  3. +4
    -0
      src/graphics.c

+ 6
- 1
configure.ac Wyświetl plik

@@ -127,7 +127,12 @@ if test "${enable_ncurses}" != "no"; then
[ac_cv_my_have_ncurses="yes" [ac_cv_my_have_ncurses="yes"
AC_DEFINE(USE_NCURSES, 1, Define to activate the ncurses backend driver) AC_DEFINE(USE_NCURSES, 1, Define to activate the ncurses backend driver)
CACA_LIBS="${CACA_LIBS} -lncurses" CACA_LIBS="${CACA_LIBS} -lncurses"
CACA_DRIVERS="${CACA_DRIVERS} ncurses"])])
CACA_DRIVERS="${CACA_DRIVERS} ncurses"
dnl Check for resizeterm or resize_term
SAVED_LIBS="${LIBS}"
LIBS="${LIBS} -lncurses"
AC_CHECK_FUNCS(resizeterm resize_term)
LIBS="${SAVED_LIBS}"])])
if test "${ac_cv_my_have_ncurses}" = "no" -a "${enable_ncurses}" = "yes"; then if test "${ac_cv_my_have_ncurses}" = "no" -a "${enable_ncurses}" = "yes"; then
AC_MSG_ERROR([cannot find ncurses development files]) AC_MSG_ERROR([cannot find ncurses development files])
fi fi


+ 2
- 0
msvc/config.h Wyświetl plik

@@ -12,6 +12,8 @@
#define HAVE_MEMORY_H 1 #define HAVE_MEMORY_H 1
/* #undef HAVE_NCURSES_H */ /* #undef HAVE_NCURSES_H */
#define HAVE_PUTENV 1 #define HAVE_PUTENV 1
/* #undef HAVE_RESIZETERM */
/* #undef HAVE_RESIZE_TERM */
/* #undef HAVE_SIGNAL */ /* #undef HAVE_SIGNAL */
/* #undef HAVE_SIGNAL_H */ /* #undef HAVE_SIGNAL_H */
/* #undef HAVE_SLANG_H */ /* #undef HAVE_SLANG_H */


+ 4
- 0
src/graphics.c Wyświetl plik

@@ -1309,7 +1309,11 @@ static void caca_handle_resize(void)
{ {
_caca_width = size.ws_col; _caca_width = size.ws_col;
_caca_height = size.ws_row; _caca_height = size.ws_row;
#if defined(HAVE_RESIZE_TERM)
resize_term(_caca_height, _caca_width); resize_term(_caca_height, _caca_width);
#else
resizeterm(_caca_height, _caca_width);
#endif
wrefresh(curscr); wrefresh(curscr);
} }
} }


Ładowanie…
Anuluj
Zapisz