mirror of
git://git.sv.gnu.org/nano.git
synced 2024-11-25 14:20:46 +03:00
tweaks: remove a band-aid condition that is no longer needed
Also, don't bother conditionalizing two booleans for the tiny version.
This commit is contained in:
parent
7287300e0d
commit
5416b9c09d
13
src/move.c
13
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
|
* smooth scrolling mode, or up half a page if we're not. If
|
||||||
* scroll_only is TRUE, scroll the edit window up one line
|
* scroll_only is TRUE, scroll the edit window up one line
|
||||||
* unconditionally. */
|
* unconditionally. */
|
||||||
if (openfile->current_y == 0
|
if (openfile->current_y == 0 || scroll_only)
|
||||||
#ifndef NANO_TINY
|
edit_scroll(UPWARD, (ISSET(SMOOTH_SCROLL) || scroll_only) ?
|
||||||
|| (ISSET(SOFTWRAP) && openfile->edittop->lineno == openfile->current->next->lineno) || scroll_only
|
1 : editwinrows / 2 + 1);
|
||||||
#endif
|
|
||||||
)
|
|
||||||
edit_scroll(UPWARD,
|
|
||||||
#ifndef NANO_TINY
|
|
||||||
(ISSET(SMOOTH_SCROLL) || scroll_only) ? 1 :
|
|
||||||
#endif
|
|
||||||
editwinrows / 2 + 1);
|
|
||||||
|
|
||||||
/* If the lines weren't already redrawn, see if they need to be. */
|
/* If the lines weren't already redrawn, see if they need to be. */
|
||||||
if (openfile->current_y > 0) {
|
if (openfile->current_y > 0) {
|
||||||
|
Loading…
Reference in New Issue
Block a user