diff options
author | in2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-03-03 23:32:15 +0800 |
---|---|---|
committer | in2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-03-03 23:32:15 +0800 |
commit | 17e632916ad1295e46dc9d2fa208334c4a96735b (patch) | |
tree | 09fbc8f939a437144d46694affe79d3b7bb8296b | |
parent | 04984dc8e37a29a788a7cf867c6ff88e65e03322 (diff) | |
download | pttbbs-17e632916ad1295e46dc9d2fa208334c4a96735b.tar pttbbs-17e632916ad1295e46dc9d2fa208334c4a96735b.tar.gz pttbbs-17e632916ad1295e46dc9d2fa208334c4a96735b.tar.bz2 pttbbs-17e632916ad1295e46dc9d2fa208334c4a96735b.tar.lz pttbbs-17e632916ad1295e46dc9d2fa208334c4a96735b.tar.xz pttbbs-17e632916ad1295e46dc9d2fa208334c4a96735b.tar.zst pttbbs-17e632916ad1295e46dc9d2fa208334c4a96735b.zip |
fix input length of voting
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk@683 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | pttbbs/mbbsd/vote.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/pttbbs/mbbsd/vote.c b/pttbbs/mbbsd/vote.c index 618da18a..a71040c9 100644 --- a/pttbbs/mbbsd/vote.c +++ b/pttbbs/mbbsd/vote.c @@ -1,4 +1,4 @@ -/* $Id: vote.c,v 1.18 2003/01/19 16:06:06 kcwu Exp $ */ +/* $Id: vote.c,v 1.19 2003/03/03 15:32:15 in2 Exp $ */ #include "bbs.h" static int total; @@ -704,9 +704,17 @@ vote_maintain(char *bname) outs("\n請依序輸入選項, 按 ENTER 完成設定"); num = 0; while (!aborted) { + if( num % 15 == 0 ){ + for( i = num ; i < num + 15 ; ++i ){ + snprintf(buf, sizeof(buf), "\033[1;30m%c)\033[m ", i + 'A'); + move((i % 15) + 2, (i / 15) * 40); + prints(buf); + } + refresh(); + } snprintf(buf, sizeof(buf), "%c) ", num + 'A'); getdata((num % 15) + 2, (num / 15) * 40, buf, - inbuf, 50, DOECHO); + inbuf, 37, DOECHO); if (*inbuf) { fprintf(fp, "%1c) %s\n", (num + 'A'), inbuf); num++; |