1
0
Fork 0
forked from len0rd/rockbox

Don't scroll past end of file list

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@779 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Björn Stenberg 2002-05-29 09:00:13 +00:00
parent 349e73079e
commit 082ba5196d

View file

@ -268,15 +268,17 @@ bool dirbrowse(char *root)
#else
case BUTTON_RIGHT:
#endif
if(dircursor+1 < TREE_MAX_ON_SCREEN) {
lcd_puts(0, LINE_Y+dircursor, " ");
dircursor++;
lcd_puts(0, LINE_Y+dircursor, "-");
}
else {
start++;
numentries = showdir(currdir, start);
lcd_puts(0, LINE_Y+dircursor, "-");
if (dircursor + start + 1 < numentries ) {
if(dircursor+1 < TREE_MAX_ON_SCREEN) {
lcd_puts(0, LINE_Y+dircursor, " ");
dircursor++;
lcd_puts(0, LINE_Y+dircursor, "-");
}
else {
start++;
numentries = showdir(currdir, start);
lcd_puts(0, LINE_Y+dircursor, "-");
}
}
break;