diff options
author | ps <ps@FreeBSD.org> | 2000-07-14 09:51:40 +0000 |
---|---|---|
committer | ps <ps@FreeBSD.org> | 2000-07-14 09:51:40 +0000 |
commit | 5d465776b9e058088e1f29636cf7cdcb0c13eb0d (patch) | |
tree | f3a476e74c05bfed5be5c76fca73660c52bd2cc5 /contrib/less/command.c | |
parent | 1b28029810e9c377087ea5a45acc8767cf0196b3 (diff) | |
download | FreeBSD-src-5d465776b9e058088e1f29636cf7cdcb0c13eb0d.zip FreeBSD-src-5d465776b9e058088e1f29636cf7cdcb0c13eb0d.tar.gz |
Import less v358.
Diffstat (limited to 'contrib/less/command.c')
-rw-r--r-- | contrib/less/command.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/contrib/less/command.c b/contrib/less/command.c index 95c529f..d898ed1 100644 --- a/contrib/less/command.c +++ b/contrib/less/command.c @@ -50,6 +50,7 @@ extern char *editor; extern char *editproto; #endif extern int screen_trashed; /* The screen has been overwritten */ +extern int shift_count; static char ungot[UNGOT_SIZE]; static char *ungotp = NULL; @@ -1502,7 +1503,8 @@ commands() case A_LSHIFT: if (number <= 0) - number = 8; + number = (shift_count > 0) ? + shift_count : sc_width / 2; if (number > hshift) number = hshift; hshift -= number; @@ -1511,7 +1513,8 @@ commands() case A_RSHIFT: if (number <= 0) - number = 8; + number = (shift_count > 0) ? + shift_count : sc_width / 2; hshift += number; screen_trashed = 1; break; |