summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiika Pekkarinen <miipekk@ihme.org>2006-04-08 08:59:47 +0000
committerMiika Pekkarinen <miipekk@ihme.org>2006-04-08 08:59:47 +0000
commit37e386f3d81ebe7ad4f32e919d529391f8f4ced0 (patch)
tree7275159b628ed2a710306f865271cfcdd6e3173a
parent53e921c4c3539fc63b85e9075986d1486b02e48c (diff)
downloadrockbox-37e386f3d81ebe7ad4f32e919d529391f8f4ced0.tar.gz
rockbox-37e386f3d81ebe7ad4f32e919d529391f8f4ced0.zip
Show progress when searching tagcache.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9560 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/tagtree.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/apps/tagtree.c b/apps/tagtree.c
index db35ee0d0c..1756617629 100644
--- a/apps/tagtree.c
+++ b/apps/tagtree.c
@@ -363,6 +363,7 @@ int tagtree_load(struct tree_context* c)
363 int namebufused = 0; 363 int namebufused = 0;
364 struct tagentry *dptr = (struct tagentry *)c->dircache; 364 struct tagentry *dptr = (struct tagentry *)c->dircache;
365 bool sort = false; 365 bool sort = false;
366 int last_tick;
366 367
367 int table = c->currtable; 368 int table = c->currtable;
368 int extra = c->currextra; 369 int extra = c->currextra;
@@ -395,6 +396,12 @@ int tagtree_load(struct tree_context* c)
395 396
396 case navibrowse: 397 case navibrowse:
397 logf("navibrowse..."); 398 logf("navibrowse...");
399#ifdef HAVE_TC_RAMCACHE
400 if (!tagcache_is_ramcache())
401#endif
402 gui_syncsplash(0, true, str(LANG_PLAYLIST_SEARCH_MSG),
403 0, csi->name);
404
398 tagcache_search(&tcs, csi->tagorder[extra]); 405 tagcache_search(&tcs, csi->tagorder[extra]);
399 for (i = 0; i < extra; i++) 406 for (i = 0; i < extra; i++)
400 { 407 {
@@ -421,6 +428,7 @@ int tagtree_load(struct tree_context* c)
421 i = 0; 428 i = 0;
422 namebufused = 0; 429 namebufused = 0;
423 c->dirfull = false; 430 c->dirfull = false;
431 last_tick = current_tick;
424 while (tagcache_get_next(&tcs)) 432 while (tagcache_get_next(&tcs))
425 { 433 {
426 dptr->newtable = tcs.result_seek; 434 dptr->newtable = tcs.result_seek;
@@ -473,6 +481,19 @@ int tagtree_load(struct tree_context* c)
473 break ; 481 break ;
474 } 482 }
475 483
484 if (!tcs.ramsearch && current_tick - last_tick > HZ/2)
485 {
486 gui_syncsplash(0, true, str(LANG_PLAYLIST_SEARCH_MSG), i,
487#if CONFIG_KEYPAD == PLAYER_PAD
488 str(LANG_STOP_ABORT)
489#else
490 str(LANG_OFF_ABORT)
491#endif
492 );
493 if (SETTINGS_CANCEL == button_get(false))
494 break ;
495 last_tick = current_tick;
496 }
476 } 497 }
477 498
478 if (sort) 499 if (sort)