nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit 5416b9c09dd3004685f1f2c0997f0cf595a479f8
parent 7287300e0d6121152d3cd616b971b7cb708d9319
Author: Benno Schulenberg <bensberg@justemail.net>
Date:   Mon, 24 Oct 2016 13:56:00 +0200

tweaks: remove a band-aid condition that is no longer needed

Also, don't bother conditionalizing two booleans for the tiny version.

Diffstat:
Msrc/move.c | 13+++----------
1 file changed, 3 insertions(+), 10 deletions(-)

diff --git a/src/move.c b/src/move.c @@ -443,16 +443,9 @@ void do_up(bool scroll_only) * smooth scrolling mode, or up half a page if we're not. If * scroll_only is TRUE, scroll the edit window up one line * unconditionally. */ - if (openfile->current_y == 0 -#ifndef NANO_TINY - || (ISSET(SOFTWRAP) && openfile->edittop->lineno == openfile->current->next->lineno) || scroll_only -#endif - ) - edit_scroll(UPWARD, -#ifndef NANO_TINY - (ISSET(SMOOTH_SCROLL) || scroll_only) ? 1 : -#endif - editwinrows / 2 + 1); + if (openfile->current_y == 0 || scroll_only) + edit_scroll(UPWARD, (ISSET(SMOOTH_SCROLL) || scroll_only) ? + 1 : editwinrows / 2 + 1); /* If the lines weren't already redrawn, see if they need to be. */ if (openfile->current_y > 0) {