From c8a46a1e88d4cca6af4cbb4414e9d560aee7ef28 Mon Sep 17 00:00:00 2001 From: in2 Date: Mon, 3 Mar 2003 15:32:15 +0000 Subject: fix input length of voting git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@683 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- mbbsd/vote.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/mbbsd/vote.c b/mbbsd/vote.c index 618da18a..a71040c9 100644 --- a/mbbsd/vote.c +++ b/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++; -- cgit v1.2.3