From 2f976c740656856523690cbb783b036df857ebc3 Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Fri, 22 Jul 2011 15:17:09 +1000 Subject: [PATCH] Make the input windows update immediately instead of needing a refresh. --- main.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/main.c b/main.c index 0c65bb31..abad2b47 100644 --- a/main.c +++ b/main.c @@ -1444,6 +1444,7 @@ static void display_pools(void) char input; opt_loginput = true; + immedok(logwin, true); updated: clear_logwin(); pthread_mutex_lock(&curses_lock); @@ -1466,7 +1467,6 @@ retry: wprintw(logwin, "[A]dd pool [R]emove pool [D]isable pool [E]nable pool\n"); wprintw(logwin, "[C]hange management strategy [S]witch pool [I]nformation\n"); wprintw(logwin, "Or press any other key to continue\n"); - wrefresh(logwin); pthread_mutex_unlock(&curses_lock); input = getch(); @@ -1541,6 +1541,7 @@ retry: } clear_logwin(); + immedok(logwin, false); opt_loginput = false; } @@ -1549,9 +1550,9 @@ static void display_options(void) char input; opt_loginput = true; + immedok(logwin, true); wprintw(logwin, "\nToggle: [D]ebug [N]ormal [S]ilent [V]erbose [R]PC debug [C]lear\n"); wprintw(logwin, "Select an option or any other key to return\n"); - wrefresh(logwin); input = getch(); if (!strncasecmp(&input, "s", 1)) { opt_quiet ^= true; @@ -1575,7 +1576,7 @@ static void display_options(void) applog(LOG_WARNING, "RPC protocol debugging %s", opt_protocol ? "enabled" : "disabled"); } else if (!strncasecmp(&input, "c", 1)) clear_logwin(); - wrefresh(logwin); + immedok(logwin, false); opt_loginput = false; }