Skip to content

Commit 5c0833b

Browse files
committed
Merge branch '4761_panel_goto_bottom_file'
* 4761_panel_goto_bottom_file: Ticket #4761: panel: fix move to bottom file on screen.
2 parents c4cfc8e + c47071c commit 5c0833b

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/filemanager/panel.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2347,6 +2347,7 @@ goto_middle_file (WPanel *panel)
23472347

23482348
unselect_item (panel);
23492349
panel->current = panel->top + panel_items (panel) / 2;
2350+
panel->current = MIN (panel->current, panel->dir.len - 1);
23502351
select_item (panel);
23512352
}
23522353

@@ -2360,6 +2361,7 @@ goto_bottom_file (WPanel *panel)
23602361

23612362
unselect_item (panel);
23622363
panel->current = panel->top + panel_items (panel) - 1;
2364+
panel->current = MIN (panel->current, panel->dir.len - 1);
23632365
select_item (panel);
23642366
}
23652367

0 commit comments

Comments
 (0)