View Single Post
Old 01-23-2011, 05:52 PM   #85
Iņigo
Guru
Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.Iņigo did not drink the Kool Aid.
 
Posts: 730
Karma: 72743
Join Date: Feb 2008
Location: Here or there
Device: iRex iLiad, iRex DR800S. K4NT. Kobo Aura, Aura One, Libra 2.
Quote:
Originally Posted by Mackx View Post
Maybe mdbindex can be modified to handle the Icon-entry in the desktop file? In that case there is no need for a separate program.
On the other hand being able to add short-cuts to application on HOME is also somewhere on my todo list (but not that high).
I thought so, but the code I'm using (icons.lua) is lua-based, and perhaps a bit slow.
F.e., for fb2 the script has to search for proper files in the db, parse the files (xml), get .png data and store on db... No fun to write all this code in C.

A fast&dirty hack is to:
. rename "/usr/bin/mdbindex" binary to "/usr/bin/mdbindex-dr"
. create a "/usr/bin/mdbindex" shell script which executes "/usr/bin/mdbindex-dr" and "icons.lua"

This shell script could contain some flags to activate the different types of files (DR-supported ones (pdf, epub, images, notes) and icons.lua-supported (.desktop and fb2 by now)).

Btw, I've attached a new version of icons.lua I've been working on this productive afternoon. It's more robust, and can delete previously-added .desktop and .fb2 thumbnails from the DB. And a new --help (or -h) flag!

Iņigo
Attached Files
File Type: gz icons.lua.gz (3.3 KB, 517 views)
Iņigo is offline   Reply With Quote