smart update: do it by chunks.
[unix-history] / usr / src / usr.bin / window / cmd5.c
CommitLineData
0fae0eb5 1#ifndef lint
14f251df 2static char *sccsid = "@(#)cmd5.c 3.1 83/08/11";
0fae0eb5
EW
3#endif
4
5#include "defs.h"
0fae0eb5 6
85af59e4
EW
7/*
8c_scroll(dir)
9int dir;
101acab4 10{
85af59e4 11 register brow = selwin->ww_scroll;
101acab4 12
85af59e4
EW
13 brow += dir * selwin->ww_w.nrow / 2;
14 if (brow < 0)
15 brow = 0;
16 else if (brow + selwin->ww_w.nrow > selwin->ww_nline)
17 brow = selwin->ww_nline - selwin->ww_w.nrow;
18 if (brow != selwin->ww_scroll) {
19 selwin->ww_scroll = brow;
20 wwredrawwin(selwin);
579ea220 21 }
0fae0eb5 22}
85af59e4 23*/