A nocolor msg print

This commit is contained in:
Arun Prakash Jana 2020-04-05 21:53:15 +05:30
parent 1195dc86e0
commit b060115a19
No known key found for this signature in database
GPG Key ID: A75979F35C080412
1 changed files with 8 additions and 3 deletions

View File

@ -556,7 +556,7 @@ static const char * const messages[] = {
"'s'shfs / 'r'clone?", "'s'shfs / 'r'clone?",
"refresh if slow", "refresh if slow",
"app name: ", "app name: ",
"'d'efault / e'x'tract / 'l'ist / 'm'ount?", "'d'efault / 'e'xtract / 'l'ist / 'm'ount?",
"plugin keys:", "plugin keys:",
"bookmark keys:", "bookmark keys:",
"invalid regex", "invalid regex",
@ -785,12 +785,17 @@ static void clearoldprompt(void)
#endif #endif
/* Messages show up at the bottom */ /* Messages show up at the bottom */
static void printmsg(const char *msg) static inline void printmsg_nc(const char *msg)
{ {
tolastln(); tolastln();
attron(COLOR_PAIR(cfg.curctx + 1) | A_REVERSE);
addstr(msg); addstr(msg);
hline(' ', xcols); hline(' ', xcols);
}
static void printmsg(const char *msg)
{
attron(COLOR_PAIR(cfg.curctx + 1) | A_REVERSE);
printmsg_nc(msg);
attroff(COLOR_PAIR(cfg.curctx + 1) | A_REVERSE); attroff(COLOR_PAIR(cfg.curctx + 1) | A_REVERSE);
} }