forked from len0rd/rockbox
Fix the bug where holding left no longer stopped at the browser root.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13983 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
9e61b1b0e6
commit
ffeccda8cd
2 changed files with 5 additions and 10 deletions
|
@ -984,6 +984,10 @@ unsigned gui_synclist_do_button(struct gui_synclist * lists,
|
||||||
return ACTION_STD_NEXT;
|
return ACTION_STD_NEXT;
|
||||||
|
|
||||||
#ifdef HAVE_LCD_BITMAP
|
#ifdef HAVE_LCD_BITMAP
|
||||||
|
case ACTION_TREE_PGRIGHT:
|
||||||
|
gui_synclist_scroll_right(lists);
|
||||||
|
gui_synclist_draw(lists);
|
||||||
|
return ACTION_TREE_PGRIGHT;
|
||||||
case ACTION_TREE_ROOT_INIT:
|
case ACTION_TREE_ROOT_INIT:
|
||||||
/* After this button press ACTION_TREE_PGLEFT is allowed
|
/* After this button press ACTION_TREE_PGLEFT is allowed
|
||||||
to skip to root. ACTION_TREE_ROOT_INIT must be defined in the
|
to skip to root. ACTION_TREE_ROOT_INIT must be defined in the
|
||||||
|
@ -995,10 +999,6 @@ unsigned gui_synclist_do_button(struct gui_synclist * lists,
|
||||||
scrolling_left = false;
|
scrolling_left = false;
|
||||||
return ACTION_STD_CANCEL;
|
return ACTION_STD_CANCEL;
|
||||||
}
|
}
|
||||||
case ACTION_TREE_PGRIGHT:
|
|
||||||
gui_synclist_scroll_right(lists);
|
|
||||||
gui_synclist_draw(lists);
|
|
||||||
return ACTION_TREE_PGRIGHT;
|
|
||||||
case ACTION_TREE_PGLEFT:
|
case ACTION_TREE_PGLEFT:
|
||||||
if(!scrolling_left && (lists->gui_list[0].offset_position == 0))
|
if(!scrolling_left && (lists->gui_list[0].offset_position == 0))
|
||||||
return ACTION_STD_CANCEL;
|
return ACTION_STD_CANCEL;
|
||||||
|
|
|
@ -523,7 +523,6 @@ static int dirbrowse()
|
||||||
bool need_update = true;
|
bool need_update = true;
|
||||||
bool exit_func = false;
|
bool exit_func = false;
|
||||||
long thumbnail_time = -1; /* for delaying a thumbnail */
|
long thumbnail_time = -1; /* for delaying a thumbnail */
|
||||||
long last_cancel = 0;
|
|
||||||
|
|
||||||
char* currdir = tc.currdir; /* just a shortcut */
|
char* currdir = tc.currdir; /* just a shortcut */
|
||||||
#ifdef HAVE_TAGCACHE
|
#ifdef HAVE_TAGCACHE
|
||||||
|
@ -605,15 +604,11 @@ static int dirbrowse()
|
||||||
if ((*tc.dirfilter == SHOW_ID3DB && tc.dirlevel == 0) ||
|
if ((*tc.dirfilter == SHOW_ID3DB && tc.dirlevel == 0) ||
|
||||||
((*tc.dirfilter != SHOW_ID3DB && !strcmp(currdir,"/"))))
|
((*tc.dirfilter != SHOW_ID3DB && !strcmp(currdir,"/"))))
|
||||||
{
|
{
|
||||||
if (last_cancel && TIME_BEFORE(current_tick, last_cancel+HZ/2))
|
if (returned_button == ACTION_STD_CANCEL)
|
||||||
{
|
|
||||||
last_cancel = 0;
|
|
||||||
break;
|
break;
|
||||||
}
|
|
||||||
else
|
else
|
||||||
return GO_TO_ROOT;
|
return GO_TO_ROOT;
|
||||||
}
|
}
|
||||||
last_cancel = current_tick;
|
|
||||||
|
|
||||||
#ifdef HAVE_TAGCACHE
|
#ifdef HAVE_TAGCACHE
|
||||||
if (id3db)
|
if (id3db)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue