summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-04-28 02:04:08 +0800
committerptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-04-28 02:04:08 +0800
commit1f5f24abc427f95cb07e660f2d58ed9d39486e0c (patch)
treeade635401b94df658c624f6292aa9d4651b0f213
parentb638a107935cd572fccbcbd0eb9c02f21d01e698 (diff)
downloadpttbbs-1f5f24abc427f95cb07e660f2d58ed9d39486e0c.tar
pttbbs-1f5f24abc427f95cb07e660f2d58ed9d39486e0c.tar.gz
pttbbs-1f5f24abc427f95cb07e660f2d58ed9d39486e0c.tar.bz2
pttbbs-1f5f24abc427f95cb07e660f2d58ed9d39486e0c.tar.lz
pttbbs-1f5f24abc427f95cb07e660f2d58ed9d39486e0c.tar.xz
pttbbs-1f5f24abc427f95cb07e660f2d58ed9d39486e0c.tar.zst
pttbbs-1f5f24abc427f95cb07e660f2d58ed9d39486e0c.zip
fix for ptt2
: : 1. 在分類看板內的各群組下的看板列表不正常 : : 會有部份的板找不到 重進群組每次大概會多出現兩個板 : : 這對小組長來說很麻煩吧 fixed...看板等victor回來再review一次 : : 2. 叮叮聲是沒之前嚴重了 不過原本如果在文章列表的最後一篇文章按↓ : : 會出現的叮叮聲現在消失了 可不可以把這個叮要回來 ^^" fixed : : 3. 換頁時可不可以跟之前一樣是換一整頁 而不是現在這樣只換半頁 @@ fixed : 4. tag 完文章按 ^D 之後的確認 能不能不要按個 y 就直接砍掉 : 應該要多按個 enter 再砍比較保險一點 default是'N'應該還好囉 我覺得這用久會比較方便 不想改了'''''''''' : 5. 在文章列表上按 ctrl + q 查詢 user 後 會接著進入設定該帳號的畫面 : 這正常嗎? XD fixed git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@1878 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--mbbsd/admin.c7
-rw-r--r--mbbsd/read.c7
-rw-r--r--mbbsd/user.c34
3 files changed, 23 insertions, 25 deletions
diff --git a/mbbsd/admin.c b/mbbsd/admin.c
index 5379d0be..aa370b1e 100644
--- a/mbbsd/admin.c
+++ b/mbbsd/admin.c
@@ -231,9 +231,10 @@ setperms(unsigned int pbits, char *pstring[])
((pbits >> (i + 16)) & 1 ? "" : ""));
}
clrtobot();
- while (getdata(b_lines - 1, 0, "Ы [A-5] ]wA [Return] G",
- choice, sizeof(choice), LCECHO)) {
- i = choice[0] - 'a';
+ while (
+ (i = getans("Ы [A-5] ]wA [Return] G"))!='\r')
+ {
+ i = i - 'a';
if (i < 0)
i = choice[0] - '0' + 26;
if (i >= NUMPERMS)
diff --git a/mbbsd/read.c b/mbbsd/read.c
index 5fcf885c..b771ccb9 100644
--- a/mbbsd/read.c
+++ b/mbbsd/read.c
@@ -238,9 +238,15 @@ cursor_pos(keeploc_t * locmem, int val, int from_top, int isshow)
return DONOTHING;
}
if (val > last_line)
+ {
+ bell();
val = last_line;
+ }
if (val <= 0)
+ {
+ bell();
val = 1;
+ }
if (val >= top && val < top + p_lines) {
if(isshow)
{
@@ -550,6 +556,7 @@ i_read_key(onekey_t * rcmdlist, keeploc_t * locmem,
break;
case Ctrl('Q'):
mode = my_query(headers[locmem->crs_ln - locmem->top_ln].owner);
+ break;
case Ctrl('S'):
if (HAS_PERM(PERM_ACCOUNTS)) {
int id;
diff --git a/mbbsd/user.c b/mbbsd/user.c
index f6681cc2..edbe4fb1 100644
--- a/mbbsd/user.c
+++ b/mbbsd/user.c
@@ -217,7 +217,7 @@ violate_law(userec_t * u, int unum)
static void Customize(void)
{
- char ans[4], done = 0, mindbuf[5];
+ char done = 0, mindbuf[5];
char *wm[3] = {"@", "i", ""};
showtitle("ӤHƳ]w", "ӤHƳ]w");
@@ -236,11 +236,7 @@ static void Customize(void)
prints("%-30s%10s\n", "D. ثe߱", mindbuf);
prints("%-30s%10s\n", "E. Gܧڪ̷R",
((cuser.uflag2 & FAVNOHILIGHT) ? "_" : "O"));
- getdata(b_lines - 1, 0, "Ы [A-E] ]wA [Return] G",
- ans, 3, DOECHO);
-
- switch( ans[0] ){
- case 'A':
+ switch(getans("Ы [A-E] ]wA [Return] G")){
case 'a':{
int currentset = cuser.uflag2 & WATER_MASK;
currentset = (currentset + 1) % 3;
@@ -249,17 +245,14 @@ static void Customize(void)
vmsg("ץyҦХ`uAsWu");
}
break;
- case 'B':
case 'b':
cuser.userlevel ^= PERM_NOOUTMAIL;
break;
- case 'C':
case 'c':
cuser.uflag2 ^= FAVNEW_FLAG;
if (cuser.uflag2 & FAVNEW_FLAG)
subscribe_newfav();
break;
- case 'D':
case 'd':{
getdata(b_lines - 1, 0, "{b߱? ",
mindbuf, sizeof(mindbuf), DOECHO);
@@ -271,7 +264,6 @@ static void Customize(void)
memcpy(currutmp->mind, mindbuf, 4);
}
break;
- case 'E':
case 'e':
cuser.uflag2 ^= FAVNOHILIGHT;
break;
@@ -280,7 +272,7 @@ static void Customize(void)
}
passwd_update(usernum, &cuser);
}
- pressanykey();
+ vmsg("]w");
}
void
@@ -288,8 +280,8 @@ uinfo_query(userec_t * u, int real, int unum)
{
userec_t x;
register int i = 0, fail, mail_changed;
- int uid;
- char ans[4], buf[STRLEN], *p;
+ int uid, ans;
+ char buf[STRLEN], *p;
char genbuf[200], reason[50];
int money = 0;
fileheader_t fhdr;
@@ -300,23 +292,22 @@ uinfo_query(userec_t * u, int real, int unum)
fail = mail_changed = 0;
memcpy(&x, u, sizeof(userec_t));
- getdata(b_lines - 1, 0, real ?
+ ans = getans(real ?
"(1)(2)]KX(3)]v(4)b(5)ID"
"(6)/_d(7)fP [0] " :
- "п (1)ק (2)]wKX (C) ӤHƳ]w ==> [0] ",
- ans, sizeof(ans), DOECHO);
+ "п (1)ק (2)]wKX (C) ӤHƳ]w ==> [0] ");
- if (ans[0] > '2' && ans[0] != 'C' && ans[0] != 'c' && !real)
- ans[0] = '0';
+ if (ans > '2' && ans != 'C' && ans != 'c' && !real)
+ ans = '0';
- if (ans[0] == '1' || ans[0] == '3') {
+ if (ans == '1' || ans == '3') {
clear();
i = 1;
move(i++, 0);
outs(msg_uid);
outs(x.userid);
}
- switch (ans[0]) {
+ switch (ans) {
case 'C':
case 'c':
Customize();
@@ -588,8 +579,7 @@ uinfo_query(userec_t * u, int real, int unum)
pressanykey();
return;
}
- getdata(b_lines - 1, 0, msg_sure_ny, ans, 3, LCECHO);
- if (*ans == 'y') {
+ if (getans(msg_sure_ny) == 'y') {
if (flag)
post_change_perm(temp, i, cuser.userid, x.userid);
if (strcmp(u->userid, x.userid)) {