Rockbox Technical Forums

Support and General Use => Audio Playback, Database and Playlists => Topic started by: Portasmith on April 14, 2009, 03:48:44 PM

Title: Hide <All tracks> and <Random>
Post by: Portasmith on April 14, 2009, 03:48:44 PM
In the database view, is there any way to hide the <All tracks> and <Random> items?  I just want to see the available albums/tracks, etc.  I didn't see anything I could use in tagnavi.config

Thanks. :)

This is on a Sansa c250 with Rockbox r20705.

EDIT: Okay, I made myself a patch for this, which I compiled and works perfect.  Since this isn't something that all users would want (nor something that would make it into a release), should/can I post this to the patch tracker?  Or can I just post it here in the forums for if another user would want to remove this functionality?
Title: Re: Hide <All tracks> and <Random>
Post by: evilnick on April 16, 2009, 10:09:52 AM
I would say that if your fix is changing tagnavi.config then it'd be best to post that in the Wiki.
If it's a patch against svn code then post it in Patches.

The forums shouldn't be used for patches, as each thread will dip "under the radar" for most users after they're on page 2. So keeping this information in the Wiki is encouraged.
Title: Re: Hide <All tracks> and <Random>
Post by: Portasmith on April 16, 2009, 11:39:19 AM
If it's a patch against svn code then post it in Patches.
Yeah, it is.  I just wasn't sure if the patches system was only to be used for patching bugs, or if it could be used also for things like this (an optional customization)?  If it's the latter, then I'll post it. :)
Title: Re: Hide <All tracks> and <Random>
Post by: JdGordon on April 17, 2009, 06:23:28 PM
there hasnt been much talk about requesting this feature, but depending how small it is, if those items can be disable with a tagnavi.config *something* then the patch might be a nice addition
Title: Re: Hide <All tracks> and <Random>
Post by: ted209 on March 09, 2011, 05:37:45 PM
I know this is an old post, but I want to do exactly this for my clip+.

I never use these menu items, so it's annoying having them right at the top of the database menu.

Any chance of posting the patch to the tracker?  Otherwise if you could post here what you did, then I can compile my own build.
Title: Re: Hide <All tracks> and <Random>
Post by: sach160 on March 27, 2011, 02:24:49 PM
Hi I'd like to do this too but can't find it in the patches. Would be great if the poster could upload the patch...
Title: Re: Hide <All tracks> and <Random>
Post by: mirrors on March 27, 2011, 03:03:34 PM
I would love to know this as well.
Title: Re: Hide <All tracks> and <Random>
Post by: ted209 on March 28, 2011, 08:50:04 AM
I worked it out in the end.  It's in the tagtree.c file, simply remove all of the following lines:

Code: [Select]
     if (tag != tag_title && tag != tag_filename)
     {
         if (offset == 0)
         {
             dptr->newtable = ALLSUBENTRIES;
             dptr->name = str(LANG_TAGNAVI_ALL_TRACKS);
             dptr++;
             current_entry_count++;
         }
         if (offset <= 1)
         {
             dptr->newtable = NAVIBROWSE;
             dptr->name = str(LANG_TAGNAVI_RANDOM);
             dptr->extraseek = -1;
             dptr++;
             current_entry_count++;
         }
         special_entry_count+=2;
     }
     
total_count += special_entry_count;

I made a patch for this, but am away from my computer for a week. I can post it at the weekend if people still want it.
Title: Re: Hide <All tracks> and <Random>
Post by: mirrors on March 28, 2011, 01:47:13 PM
Where exactly is this file located? I can't seem to find it...  ???
Title: Re: Hide <All tracks> and <Random>
Post by: Chronon on March 28, 2011, 01:52:30 PM
It's in the apps directory.

http://svn.rockbox.org/viewvc.cgi/trunk/apps/tagtree.c?revision=29387&view=markup



Title: Re: Hide <All tracks> and <Random>
Post by: AlexP on March 28, 2011, 03:52:58 PM
Where exactly is this file located? I can't seem to find it...  ???

In the source code, you will need to edit it then build Rockbox.
Title: Re: Hide <All tracks> and <Random>
Post by: sach160 on March 29, 2011, 06:21:12 AM
Woah - compiling source code looks tricky, I'm not that technically minded... I'm sure I'd mess it up. Is there no easier way of achieving this for the casual Rockbox user? :(
Title: Re: Hide <All tracks> and <Random>
Post by: ted209 on March 29, 2011, 06:37:24 AM
You could try the build I made - it also has a few other patches included.  I've been using it for the last few days without issues:

http://www.anythingbutipod.com/forum/showpost.php?p=544846&postcount=8
Title: Re: Hide <All tracks> and <Random>
Post by: sach160 on March 29, 2011, 06:47:18 AM
Many thanks Ted - from your post I see the SD card isn't working on this build and I need my SD card. Is the link you posted the best place to keep an eye on for any updates you make to your build? Cheers.
Title: Re: Hide <All tracks> and <Random>
Post by: ted209 on March 29, 2011, 07:03:34 AM
I think you misread my post (it wasn't very clear!).  My SD card does work on that build, I was just stating that if I compiled a newer version, then the SD card no longer worked.
Title: Re: Hide <All tracks> and <Random>
Post by: sach160 on March 29, 2011, 07:49:43 AM
Thanks Ted! I love the long press home as WPS hotkey too. Your build is far more intuitive that the standard build -  I was getting annoyed at having to press multiple buttons to get back to the WPS from certain places. Pretty new to Rockbox but many thanks - this makes it much better for me :)

Will you be posting your builds on the same thread?
Title: Re: Hide <All tracks> and <Random>
Post by: ted209 on March 29, 2011, 09:03:27 AM
I agree, the standard keymapping on the clip is unintuitive. In my view it should always be easy to get back to the WPS (without having to look at the screen or pressing 2 buttons at the same time).

I'll make another build in the next few weeks (including all the recent changes to SD card access) and post it to the same forums.
Title: Re: Hide <All tracks> and <Random>
Post by: sach160 on March 29, 2011, 09:05:09 AM
Awesome Ted - many thanks!
Title: Re: Hide <All tracks> and <Random>
Post by: chopstickkk on November 18, 2012, 10:37:55 AM
Sorry for bringing up an old topic.

But is a recompile and build the only way to achieve this?

As a second best I would accept if you were able to move the <All tracks> and <Random> to the bottom of the lists.

It's much more intuitive to keep pressing forward repeatedly to get to the first album then the first song of that album. (Not the first song of <all tracks> as is the case)

Thanks in advance!
John.
Title: Re: Hide <All tracks> and <Random>
Post by: mirrors on November 18, 2012, 01:04:36 PM
I can't believe I'm still subscribed to this thread almost two years later...

This "feature" really annoys me too. What device do you want this compiled for? I'll post the .zip.  ;)
Title: Re: Hide <All tracks> and <Random>
Post by: chopstickkk on November 18, 2012, 01:40:31 PM
I can't believe I'm still subscribed to this thread almost two years later...

This "feature" really annoys me too. What device do you want this compiled for? I'll post the .zip.  ;)

Oh wow that'd be great if you can.

I've a Sansa Clip+.

Cheers,
John.
Title: Re: Hide <All tracks> and <Random>
Post by: mirrors on November 18, 2012, 06:15:12 PM
I have a Sansa Clip+ as well! I guess this gives me an excuse to update.

http://www.mediafire.com/?01jxqu22u9qo18m

EDIT

Quote from: https://www.gnu.org/licenses/gpl-2.0.html
3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following:

    a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange;

https://github.com/Rockbox/rockbox
http://www.mediafire.com/?s3acr7m3x2tytqf
Title: Re: Hide <All tracks> and <Random>
Post by: chopstickkk on November 19, 2012, 03:51:01 AM
I have a Sansa Clip+ as well! I guess this gives me an excuse to update.

http://www.mediafire.com/?01jxqu22u9qo18m

Amazing! Thanks a million.

Although I've never manually installed before, I just used the Rockbox Utility. I'm trying to make sense of http://www.rockbox.org/wiki/SansaAMS#Installation (http://www.rockbox.org/wiki/SansaAMS#Installation) but do I need to do all these steps if I'm using your .zip and if I already have a successful Rockbox installation on the Clip+?

Thanks again and sorry for the newbness!
Title: Re: Hide <All tracks> and <Random>
Post by: gevaerts on November 19, 2012, 05:43:27 AM
I have a Sansa Clip+ as well! I guess this gives me an excuse to update.

http://www.mediafire.com/?01jxqu22u9qo18m

Do you have the source code for that build somehwere?
Title: Re: Hide <All tracks> and <Random>
Post by: mirrors on November 19, 2012, 09:15:49 AM
Although I've never manually installed before, I just used the Rockbox Utility. I'm trying to make sense of http://www.rockbox.org/wiki/SansaAMS#Installation (http://www.rockbox.org/wiki/SansaAMS#Installation) but do I need to do all these steps if I'm using your .zip and if I already have a successful Rockbox installation on the Clip+?

Just unzip it to the root of your device. Make sure to overwrite everything if it prompts you. You're just replacing the .rockbox folder.

Do you have the source code for that build somehwere?

I do. However, it's quite large (329 MB). I can compile it for a specific device if you'd like.
Title: Re: Hide <All tracks> and <Random>
Post by: gevaerts on November 19, 2012, 11:07:15 AM
Do you have the source code for that build somehwere?

I do. However, it's quite large (329 MB). I can compile it for a specific device if you'd like.

That's not the point. This is a matter of GPL compliance. You shouldn't distribute builds without matching source (unless you go for the written offer valid for at least three years route)
Title: Re: Hide <All tracks> and <Random>
Post by: saratoga on November 19, 2012, 11:09:41 AM
I do. However, it's quite large (329 MB). I can compile it for a specific device if you'd like.

The diff is probably just a few hundred bytes, so you should include it with the binary. 
Title: Re: Hide <All tracks> and <Random>
Post by: chopstickkk on November 19, 2012, 11:19:39 AM
Just unzip it to the root of your device.

That's what I thought but I didn't want to risk owning a brick! (Or in the Clip+'s case - a pebble!)

Thanks a million again Mirrors.
Title: Re: Hide <All tracks> and <Random>
Post by: mirrors on November 19, 2012, 06:04:23 PM
That's not the point. This is a matter of GPL compliance. You shouldn't distribute builds without matching source (unless you go for the written offer valid for at least three years route)

I apologize for my non-compliance.

Quote from: https://www.softwarefreedom.org/resources/2008/compliance-guide.html
For GPLv2, the source code offer is fulfilled only with physical media.

I guess that's out of the question. See my original post.
Title: Re: Hide <All tracks> and <Random>
Post by: saratoga on November 19, 2012, 06:09:53 PM
I guess that's out of the question. See my original post.

FWIW, its strongly preferred to post a patch, since its smaller and *much* easier for other people to understand what you changed.
Title: Re: Hide <All tracks> and <Random>
Post by: mirrors on November 19, 2012, 09:16:05 PM
FWIW, its strongly preferred to post a patch, since its smaller and *much* easier for other people to understand what you changed.

Thanks for the advice.
Title: Re: Hide <All tracks> and <Random>
Post by: gevaerts on November 20, 2012, 04:16:48 AM
Thanks!