浏览代码

* configure.ac src/graphics:

+ Check for resize_term and resizeterm in -lncurses.
tags/v0.99.beta14
Sam Hocevar sam 22 年前
父节点
当前提交
e80006de20
共有 3 个文件被更改,包括 12 次插入1 次删除
  1. +6
    -1
      configure.ac
  2. +2
    -0
      msvc/config.h
  3. +4
    -0
      src/graphics.c

+ 6
- 1
configure.ac 查看文件

@@ -127,7 +127,12 @@ if test "${enable_ncurses}" != "no"; then
[ac_cv_my_have_ncurses="yes"
AC_DEFINE(USE_NCURSES, 1, Define to activate the ncurses backend driver)
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
AC_MSG_ERROR([cannot find ncurses development files])
fi


+ 2
- 0
msvc/config.h 查看文件

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


+ 4
- 0
src/graphics.c 查看文件

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


正在加载...
取消
保存