diff options
author | Miika Pekkarinen <miipekk@ihme.org> | 2006-07-16 15:04:46 +0000 |
---|---|---|
committer | Miika Pekkarinen <miipekk@ihme.org> | 2006-07-16 15:04:46 +0000 |
commit | 0042201bb387398494e75f24f69d4039251e59c9 (patch) | |
tree | 76830aadb907d85d41d6ae65dfa141742ed2fa13 /apps/tagtree.c | |
parent | 11e229ffa6612d7e97e51bfa4ed399f4f63bd4f6 (diff) | |
download | rockbox-0042201bb387398494e75f24f69d4039251e59c9.tar.gz rockbox-0042201bb387398494e75f24f69d4039251e59c9.zip |
Initial changelog support (only export, no import yet) and added
an option to search by filename.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10219 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/tagtree.c')
-rw-r--r-- | apps/tagtree.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/apps/tagtree.c b/apps/tagtree.c index 396248d7ce..f5c100f6ea 100644 --- a/apps/tagtree.c +++ b/apps/tagtree.c | |||
@@ -137,6 +137,7 @@ static int get_tag(int *tag) | |||
137 | MATCH(tag, buf, "genre", tag_genre); | 137 | MATCH(tag, buf, "genre", tag_genre); |
138 | MATCH(tag, buf, "length", tag_length); | 138 | MATCH(tag, buf, "length", tag_length); |
139 | MATCH(tag, buf, "title", tag_title); | 139 | MATCH(tag, buf, "title", tag_title); |
140 | MATCH(tag, buf, "filename", tag_filename); | ||
140 | MATCH(tag, buf, "tracknum", tag_tracknumber); | 141 | MATCH(tag, buf, "tracknum", tag_tracknumber); |
141 | MATCH(tag, buf, "year", tag_year); | 142 | MATCH(tag, buf, "year", tag_year); |
142 | MATCH(tag, buf, "playcount", tag_playcount); | 143 | MATCH(tag, buf, "playcount", tag_playcount); |
@@ -415,6 +416,17 @@ static void tagtree_unbuffer_event(struct mp3entry *id3, bool last_track) | |||
415 | tagcache_search_finish(&tcs); | 416 | tagcache_search_finish(&tcs); |
416 | } | 417 | } |
417 | 418 | ||
419 | bool tagtree_export(void) | ||
420 | { | ||
421 | gui_syncsplash(0, true, str(LANG_WAIT)); | ||
422 | if (!tagcache_create_changelog(&tcs)) | ||
423 | { | ||
424 | gui_syncsplash(HZ*2, true, str(LANG_FAILED)); | ||
425 | } | ||
426 | |||
427 | return false; | ||
428 | } | ||
429 | |||
418 | void tagtree_init(void) | 430 | void tagtree_init(void) |
419 | { | 431 | { |
420 | int fd; | 432 | int fd; |
@@ -553,7 +565,7 @@ int retrieve_entries(struct tree_context *c, struct tagcache_search *tcs, | |||
553 | current_entry_count = 0; | 565 | current_entry_count = 0; |
554 | c->dirfull = false; | 566 | c->dirfull = false; |
555 | 567 | ||
556 | if (tag != tag_title) | 568 | if (tag != tag_title && tag != tag_filename) |
557 | { | 569 | { |
558 | if (offset == 0) | 570 | if (offset == 0) |
559 | { | 571 | { |
@@ -576,7 +588,7 @@ int retrieve_entries(struct tree_context *c, struct tagcache_search *tcs, | |||
576 | 588 | ||
577 | dptr->newtable = navibrowse; | 589 | dptr->newtable = navibrowse; |
578 | dptr->extraseek = tcs->result_seek; | 590 | dptr->extraseek = tcs->result_seek; |
579 | if (tag == tag_title) | 591 | if (tag == tag_title || tag == tag_filename) |
580 | dptr->newtable = playtrack; | 592 | dptr->newtable = playtrack; |
581 | 593 | ||
582 | if (!tcs->ramsearch || fmt->valid) | 594 | if (!tcs->ramsearch || fmt->valid) |