summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Eden <sven.eden@gmx.de>2013-02-11 18:45:05 +0100
committerSven Eden <sven.eden@gmx.de>2013-02-11 18:45:05 +0100
commit053dd554d7e46ae10b2d6e4dd1dac0058cc86b35 (patch)
treeba319797ce74a924935212bd2689de65e4b8ad85 /ufed-curses-checklist.c
parentAdded local "default" settings from IUSE to output string (diff)
downloadufed-053dd554d7e46ae10b2d6e4dd1dac0058cc86b35.tar.gz
ufed-053dd554d7e46ae10b2d6e4dd1dac0058cc86b35.tar.bz2
ufed-053dd554d7e46ae10b2d6e4dd1dac0058cc86b35.zip
Added reading of local "default" setting int read_flags() and changed display to show IUSE defaults if set instead of global defaults for local descriptions.
Diffstat (limited to 'ufed-curses-checklist.c')
-rw-r--r--ufed-curses-checklist.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/ufed-curses-checklist.c b/ufed-curses-checklist.c
index 934b92d..227dc20 100644
--- a/ufed-curses-checklist.c
+++ b/ufed-curses-checklist.c
@@ -141,7 +141,7 @@ static void read_flags(void)
ERROR_EXIT(-1, "Description read failed on line %d\n\"%s\"\n", lineNum + 1, line);
// Check stats
- if ((state.end - state.start) != 6)
+ if ((state.end - state.start) != 7)
ERROR_EXIT(-1, "Illegal description stats on line %d:\n\"%s\"\n", lineNum + 1, line);
// Add description line to flag:
@@ -339,7 +339,10 @@ static int drawflag(sFlag* flag, bool highlight)
mvwaddch(wLst, line, minwidth + 1, special);
} else {
wattrset(wLst, COLOR_PAIR(3));
- mvwaddch(wLst, line, minwidth + 1, flag->stateDefault);
+ if (' ' == flag->desc[idx].stateDefault)
+ mvwaddch(wLst, line, minwidth + 1, flag->stateDefault);
+ else
+ mvwaddch(wLst, line, minwidth + 1, flag->desc[idx].stateDefault);
}
++line;