summaryrefslogtreecommitdiffstats
path: root/CRT.c
diff options
context:
space:
mode:
authorHisham Muhammad <hisham@gobolinux.org>2015-02-04 11:41:18 -0200
committerHisham Muhammad <hisham@gobolinux.org>2015-02-04 11:41:53 -0200
commit4a26ac05b09286af595035ff76004782298dd531 (patch)
treee5629e0439f617b99753ccac8af634723d4d4938 /CRT.c
parentcfc773f7ee5268d8443c640f6478b57bad45b404 (diff)
Let's see if responsiveness is still good using the full CRT_delay
in ncurses. CPU usage goes down noticeably. (Also, add missing comma, sorry.)
Diffstat (limited to 'CRT.c')
-rw-r--r--CRT.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/CRT.c b/CRT.c
index 60e2c4e9..87369d35 100644
--- a/CRT.c
+++ b/CRT.c
@@ -50,7 +50,7 @@ typedef enum ColorSchemes_ {
COLORSCHEME_BLACKONWHITE = 2,
COLORSCHEME_LIGHTTERMINAL = 3,
COLORSCHEME_MIDNIGHT = 4,
- COLORSCHEME_BLACKNIGHT = 5
+ COLORSCHEME_BLACKNIGHT = 5,
LAST_COLORSCHEME = 6,
} ColorSchemes;
@@ -144,7 +144,7 @@ const char **CRT_treeStr = CRT_treeStrAscii;
static bool CRT_hasColors;
-static int CRT_delay = 0;
+int CRT_delay = 0;
bool CRT_utf8 = false;
@@ -189,9 +189,9 @@ int CRT_colorSchemes[LAST_COLORSCHEME][LAST_COLORELEMENT] = {
[MEMORY_BUFFERS] = ColorPair(Blue,Black),
[MEMORY_BUFFERS_TEXT] = A_BOLD | ColorPair(Blue,Black),
[MEMORY_CACHE] = ColorPair(Yellow,Black),
- [LOAD_AVERAGE_FIFTEEN] = A_NORMAL,
- [LOAD_AVERAGE_FIVE] = ColorPair(Cyan,Black),
- [LOAD_AVERAGE_ONE] = A_BOLD | ColorPair(Cyan,Black),
+ [LOAD_AVERAGE_FIFTEEN] = ColorPair(Cyan,Black),
+ [LOAD_AVERAGE_FIVE] = A_BOLD | ColorPair(Cyan,Black),
+ [LOAD_AVERAGE_ONE] = A_BOLD | ColorPair(White,Black),
[LOAD] = A_BOLD,
[HELP_BOLD] = A_BOLD | ColorPair(Cyan,Black),
[CLOCK] = A_BOLD,
@@ -524,7 +524,7 @@ static void CRT_handleSIGTERM(int sgn) {
void CRT_init(int delay, int colorScheme) {
initscr();
noecho();
- CRT_delay = delay/2;
+ CRT_delay = delay;
if (CRT_delay == 0) {
CRT_delay = 1;
}

© 2014-2024 Faster IT GmbH | imprint | privacy policy