Rockbox

This is the bug/patch tracker for Rockbox. Click here for more information.

Quick links: Bugs · Patches · Rockbox frontpage

Tasklist

FS#9034 - Alphabetically sort the list of plugins shown after 'Open With...'

Attached to Project: Rockbox
Opened by Alexander Levin (fml2) - Saturday, 24 May 2008, 23:19 GMT+2
Last edited by Yoshihisa Uchida (Uchida) - Tuesday, 08 June 2010, 13:07 GMT+2
Task Type Patches
Category Applications
Status Unconfirmed   Reopened
Assigned To No-one
Player Type All players
Severity Low
Priority Normal
Reported Version Daily build (which?)
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Private No

Details

I think this is good since now the plugins in the list appear in the order of their occurrence in viewers.config which is rather random.
This task depends upon

Comment by Alexander Levin (fml2) - Saturday, 24 May 2008, 23:19 GMT+2
And now with the patch
   viewers_sort_alphabetically.patch (1.8 KiB)
 apps/filetypes.c |   26 ++++++++++++++++++++++----
 1 file changed, 22 insertions(+), 4 deletions(-)

Comment by Alexander Levin (fml2) - Saturday, 24 May 2008, 23:46 GMT+2
A small correction: always show the splash. Otherwise you get an empty list. And that's confusing.
   viewers_sort_alphabetically.patch (2.1 KiB)
 apps/filetypes.c |   30 ++++++++++++++++++++++++------
 1 file changed, 24 insertions(+), 6 deletions(-)

Comment by Alexander Levin (fml2) - Saturday, 24 May 2008, 23:48 GMT+2
And now without debugging printf's
   viewers_sort_alphabetically.patch (2 KiB)
 apps/filetypes.c |   28 ++++++++++++++++++++++------
 1 file changed, 22 insertions(+), 6 deletions(-)

Comment by Paul Louden (Llorean) - Sunday, 25 May 2008, 04:17 GMT+2
Wouldn't it make MUCH more sense to just fix viewers.config, then leave "custom sorting of the Open With screen" as a feature by modifying viewers.config?
Comment by Alexander Levin (fml2) - Sunday, 25 May 2008, 10:44 GMT+2
That would indeed make sense. But viewers.config (IIUC) has never been considered as a mean to sort (or to set the order of ) entries in the menu. Just the implementation makes it so. If we promote it to a 'desired' and 'official' feature then yes, editing the file will be more appropriate and flexible approach. But now it's just by coincidence.

BTW: editing the file might be tricky for a normal user because entries can occur many times. If I understand the implementation right, the position of a plugin in the menu list is defined by its first occurrence in viewers.config.
Comment by Alexander Levin (fml2) - Sunday, 25 May 2008, 12:01 GMT+2
For the case that we will do promote this to a feature: attached is viewers.config with entries sorted by their simple names.
   viewers_config_sorted.patch (1.9 KiB)
 apps/plugins/viewers.config |   54 ++++++++++++++++++++++----------------------
 1 file changed, 27 insertions(+), 27 deletions(-)

Comment by Yoshihisa Uchida (Uchida) - Tuesday, 08 June 2010, 13:08 GMT+2
reopen this task.
reason: text file is read by the sort plugin instead of the text viewer plugin. then, text file is broken.

Loading...