summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mbbsd/Makefile1
-rw-r--r--mbbsd/name.c19
2 files changed, 13 insertions, 7 deletions
diff --git a/mbbsd/Makefile b/mbbsd/Makefile
index 4bfb9e6f..749dd32f 100644
--- a/mbbsd/Makefile
+++ b/mbbsd/Makefile
@@ -122,6 +122,7 @@ ctags:
ctags *.c ../include/*.h ../common/sys/*.c ../common/bbs/*.c
test: $(PROG)
+ killall -TERM testmbbsd || true
killall -9 testmbbsd || true
cp mbbsd testmbbsd
./testmbbsd 9000
diff --git a/mbbsd/name.c b/mbbsd/name.c
index 4e9d7134..59c9c471 100644
--- a/mbbsd/name.c
+++ b/mbbsd/name.c
@@ -2,11 +2,18 @@
#include "bbs.h"
static word_t *current = NULL;
-static char * const msg_more = "-- More --";
typedef char (*arrptr)[];
/* name complete for user ID */
+static void
+prompt_more()
+{
+ move(b_lines, 0); clrtoeol();
+ outs(ANSI_COLOR(1;36;44));
+ prints("%-*s" ANSI_RESET, t_columns-2, " ◆ 按空白鍵可列出更多項目 ");
+}
+
//-----------------------------------------------------------------------
void NameList_init(struct NameList *self)
@@ -476,7 +483,7 @@ namecomplete(const char *prompt, char *data)
len = MaxLen(morelist, p_lines);
}
if (morelist) {
- vmsg(msg_more);
+ prompt_more();
}
continue;
}
@@ -601,7 +608,7 @@ namecomplete2(struct NameList *namelist, const char *prompt, char *data)
len = NameList_MaxLen(&sublist, viewoffset, p_lines);
}
if (viewoffset < NameList_length(&sublist)) {
- vmsg(msg_more);
+ prompt_more();
}
continue;
}
@@ -791,9 +798,7 @@ usercomplete(const char *prompt, char *data)
len = UserMaxLen((arrptr) cwlist, cwnum, morenum, p_lines);
}
if (morenum < cwnum) {
- move(b_lines, 0); clrtoeol();
- outs(msg_more);
- // vmsg(msg_more);
+ prompt_more();
} else
morenum = 0;
@@ -969,7 +974,7 @@ generalnamecomplete(const char *prompt, char *data, int len, size_t nmemb,
col += len + 2;
}
if (morelist != end + 1) {
- vmsg(msg_more);
+ prompt_more();
}
continue;