diff options
| -rw-r--r-- | apps/tree.c | 11 | ||||
| -rw-r--r-- | firmware/mpeg.c | 7 |
2 files changed, 9 insertions, 9 deletions
diff --git a/apps/tree.c b/apps/tree.c index b43c1d7..a071ce7 100644 --- a/apps/tree.c +++ b/apps/tree.c @@ -358,6 +358,7 @@ bool dirbrowse(char *root) break; case BUTTON_ON: + lcd_stop_scroll(); wps_show(); restore = true; break; @@ -370,13 +371,11 @@ bool dirbrowse(char *root) numentries = showdir(currdir, start); put_cursorxy(0, CURSOR_Y + LINE_Y+dircursor, true); } - else { - lcd_stop_scroll(); - if ( numentries ) - lcd_puts_scroll(LINE_X, LINE_Y+dircursor, - dircacheptr[start+dircursor]->name); - } + lcd_stop_scroll(); + if ( numentries ) + lcd_puts_scroll(LINE_X, LINE_Y+dircursor, + dircacheptr[start+dircursor]->name); lcd_update(); } diff --git a/firmware/mpeg.c b/firmware/mpeg.c index 41be070..c21997e 100644 --- a/firmware/mpeg.c +++ b/firmware/mpeg.c @@ -283,12 +283,13 @@ void DEI3(void) /* will we move across the track boundary? */ if (( mp3buf_read <= id3tags[0].mempos ) && - ( mp3buf_read + last_dma_chunk_size > id3tags[0].mempos )) { + ( (mp3buf_read + last_dma_chunk_size) > id3tags[0].mempos )) { /* shift array so index 0 is current track */ int i; - for (i=0; i<MAX_ID3_TAGS-1; i++) + for (i=0; i<last_tag-1; i++) id3tags[i] = id3tags[i+1]; - last_tag--; + if ( last_tag ) + last_tag--; } } else |