summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 31832b2)
raw | patch | inline | side by side (parent: 31832b2)
author | Kalle Wallin <kaw@linux.se> | |
Sat, 27 Mar 2004 16:34:56 +0000 (16:34 +0000) | ||
committer | Kalle Wallin <kaw@linux.se> | |
Sat, 27 Mar 2004 16:34:56 +0000 (16:34 +0000) |
screen.c | patch | blob | history | |
screen.h | patch | blob | history |
diff --git a/screen.c b/screen.c
index 37f5146222b07db5615dae479dfd684fab25cd6c..18feab9a0d9484d4fb4a3c2f8dd8c8c8d75e869a 100644 (file)
--- a/screen.c
+++ b/screen.c
/* return from getch() without blocking */
// nodelay(stdscr, TRUE);
keypad(stdscr, TRUE);
- timeout(100); /*void wtimeout(WINDOW *win, int delay);*/
+ timeout(SCREEN_TIMEOUT);
if( COLS<SCREEN_MIN_COLS || LINES<SCREEN_MIN_ROWS )
{
screen_cmd(mpd_client_t *c, command_t cmd)
{
int n;
- // char buf[256];
screen_mode_t new_mode = screen->mode;
switch(screen->mode)
diff --git a/screen.h b/screen.h
index 78ca39c48f4005e155573d036551f287340320eb..82033d87536e7474583887a2430bb805dcfde845 100644 (file)
--- a/screen.h
+++ b/screen.h
#define SCREEN_MIN_COLS 14
#define SCREEN_MIN_ROWS 5
+/* timeout for non blocking read [ms] */
+#define SCREEN_TIMEOUT 100
+
#define IS_PLAYING(s) (s==MPD_STATUS_STATE_PLAY)
#define IS_PAUSED(s) (s==MPD_STATUS_STATE_PAUSE)