diff options
author | Jaroslav Kysela <perex@perex.cz> | 2009-08-31 17:03:04 +0200 |
---|---|---|
committer | Jaroslav Kysela <perex@perex.cz> | 2009-08-31 17:13:36 +0200 |
commit | defee56c4184cbd78907a62dce69a4b4f5e2c00a (patch) | |
tree | 4445808a80cd0d22007b1f6e947a3cde91776823 | |
parent | ca0ff77c7c6f2b137b48aac234d49e122fd7d553 (diff) | |
download | alsa-utils-defee56c4184cbd78907a62dce69a4b4f5e2c00a.tar.gz |
alsamixer: Improve set_escdelay() function availability detectionv1.0.21
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
-rw-r--r-- | alsamixer/mainloop.c | 2 | ||||
-rw-r--r-- | configure.in | 5 |
2 files changed, 6 insertions, 1 deletions
diff --git a/alsamixer/mainloop.c b/alsamixer/mainloop.c index 7a5ffdc..eddaf3b 100644 --- a/alsamixer/mainloop.c +++ b/alsamixer/mainloop.c @@ -44,7 +44,7 @@ void initialize_curses(bool use_color) curses_initialized = initscr(); cbreak(); noecho(); -#ifdef NCURSES_VERSION +#ifdef HAVE_CURSES_ESCDELAY set_escdelay(100); #endif window_size_changed(); /* update screen_lines/cols */ diff --git a/configure.in b/configure.in index ec2a8bc..931d034 100644 --- a/configure.in +++ b/configure.in @@ -171,6 +171,11 @@ if test x$alsamixer = xtrue; then fi LIBS="$CURSESLIB $LIBS" + AC_TRY_LINK([#include <panel.h>], [set_escdelay(100);],[HAVE_CURSES_ESCDELAY="yes"]) + if test "$HAVE_CURSES_ESCDELAY" = "yes"; then + AC_DEFINE([HAVE_CURSES_ESCDELAY], 1, [Have curses set_escdelay]) + fi + if test "$USE_NLS" = "yes"; then AC_MSG_CHECKING([for curses NLS support]) dnl In theory, a single-byte curses works just fine in ISO 8859-* locales. |