Commit 1144d21ac0a468b7d3893ec69f9329ff0d5391bc

Stefan Sperling 2019-06-21T22:34:21

don't skip top-most item when scrolling upwards in tog log

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
diff --git a/tog/tog.c b/tog/tog.c
index 8a4204e..1e70527 100644
--- a/tog/tog.c
+++ b/tog/tog.c
@@ -1904,10 +1904,9 @@ input_log_view(struct tog_view **new_view, struct tog_view **dead_view,
 			break;
 		if (s->selected > 0)
 			s->selected--;
-		if (s->selected > 0)
-			break;
-		scroll_up(view, &s->first_displayed_entry, 1,
-		    &s->commits);
+		else
+			scroll_up(view, &s->first_displayed_entry, 1,
+			    &s->commits);
 		break;
 	case KEY_PPAGE:
 	case CTRL('b'):