diff options
author | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2007-12-25 17:33:36 +0800 |
---|---|---|
committer | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2007-12-25 17:33:36 +0800 |
commit | 50ea759591cb9bd71084ca393f827371cc0e031f (patch) | |
tree | 84bceb8fbd68ac801f0b1aecc4e45392c172a782 | |
parent | b0976e9c84d34b63b90e9a5e4f9971338a78d39f (diff) | |
download | pttbbs-50ea759591cb9bd71084ca393f827371cc0e031f.tar pttbbs-50ea759591cb9bd71084ca393f827371cc0e031f.tar.gz pttbbs-50ea759591cb9bd71084ca393f827371cc0e031f.tar.bz2 pttbbs-50ea759591cb9bd71084ca393f827371cc0e031f.tar.lz pttbbs-50ea759591cb9bd71084ca393f827371cc0e031f.tar.xz pttbbs-50ea759591cb9bd71084ca393f827371cc0e031f.tar.zst pttbbs-50ea759591cb9bd71084ca393f827371cc0e031f.zip |
-pfterm: FTCROW/FTAROW works with ft.y, not ft.ry. Never use them in refresh() internal loop.
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3743 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | mbbsd/pfterm.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/mbbsd/pfterm.c b/mbbsd/pfterm.c index b26e2291..5afb7a87 100644 --- a/mbbsd/pfterm.c +++ b/mbbsd/pfterm.c @@ -766,13 +766,13 @@ refresh(void) for (i = ft.rx; i < x; i++) { // if same attribute, simply accept. - if (FTAROW[i] == ft.rattr && touched) + if (FTAMAP[y][i] == ft.rattr && touched) continue; // XXX spaces may accept (BG=rBG), // but that will also change cached attribute. - if (!FTCHAR_ISBLANK(FTCROW[i])) + if (!FTCHAR_ISBLANK(FTCMAP[y][i])) break; - if (FTATTR_GETBG(FTAROW[i]) != FTATTR_GETBG(ft.rattr)) + if (FTATTR_GETBG(FTAMAP[y][i]) != FTATTR_GETBG(ft.rattr)) break; } if (i != x) @@ -789,7 +789,7 @@ refresh(void) for (i = ft.rx; i < x; i++) { fterm_rawc(FTDC[i]); - FTAROW[i] = FTOAMAP[y][i]; // spaces will change attribute... + FTAMAP[y][i] = FTOAMAP[y][i]; // spaces may change attr... ft.rx++; } @@ -2125,6 +2125,7 @@ int main(int argc, char* argv[]) getchar(); #endif +#if 0 // test resize clear(); move(1, 0); @@ -2137,8 +2138,9 @@ int main(int argc, char* argv[]) outs("2nd line\n"); refresh(); getchar(); +#endif -#if 0 +#if 1 // test optimization clear(); move(1, 0); |