• Status Closed
  • Percent Complete
  • Task Type Patches
  • Category
  • Assigned To No-one
  • Operating System
  • Severity Low
  • Priority Very Low
  • Reported Version
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by hbacke - 2004-01-18
Last edited by zagor - 2004-05-22

FS#1940 - Viewing files with plugins.

Here is my attemt to implement the scheme in mail
This patch is not completete yet, it is still a proof of

I’ve made a few changes to this scheme.
- /.rockbox/viewers.config and /.rockbox/viewers are
read/scanned at bootup if no /.rockbox/.viewers.cache
exist. This way we always know what extensions are
supported, and we only get excessive filereads on the
first boot.
- /.rockbox/viewers.config and /.rockbox/viewers are
not read/scanned when a viewer plugin is called.
Instead there is a refresh of .viewers.cache

if a plugins is missing or have filesize zero.

- If a new viewer plugin is added .viewers.cache has to
be refreshed, since this will not be done automagically
I’ve added an option to

settings->system-manage settings->reset plugin list

- I’ve made the assumption that for example
txt-viewer.rock and viewer.rock will be in
the /.rockbox/viewers folder, and then no rocks with
an extension prefix should be displayed in the
onplay→“open with” menu.

Things left to do
- code policeing
- commenting of the code
- add splashes for some of the error conditions
- add language strings
- figure out a sane value for string_buffer in filetypes.c

It's set to 1000 bytes, but I think it can be reduced.

- One known bug, A second reset of the plugin list will
freeze the unit.

Daniel’s patch mentioned in
should be applied before this patch.

Closed by  zagor
2004-05-22 00:43
Reason for closing:  Accepted

The reset bug is now solved.


Sane values for buffers and tables,
filesize zero checked when viewers.config read,
compiles for the player.

I think the logic is there now, tome for code policeing.


code policeing, splashes, comments and language strings
done. A few bugs crushed also.

The only thing left to do, if there ar no bugs left, is to
remove DEBUGF statements from filetypes.c


Added a missing language string,
verification of viewers when reading viewers.config


Updated to latest cvs

Updated to latest cvs.


Updated to latest cvs.


Updated to latestcvs.


Updated to daily cvs


Updated to latest cvs.



Available keyboard shortcuts


Task Details

Task Editing