Major refactor of e_fm2_icon_get() and minor optimizations.

* split e_fm2_icon_get() to make it reuse more code paths.

 * lots of new internal functions with _e_fm2_icon_ prefix are born,
   try to reuse them as much as possible so we have less places to
   change if we move to something else (hint: using FreeDesktop.Org
   icons)

 * optimize e_fm2_icons_update() and few others to do not copy
   sd->realpath all the time, it is loop invariant there.

 * comparison of mime icon "DESKTOP" and "THUMB" are now fast pointer
   comparison since they're all eina_stringshare'd.

 * themes can now differentiate between file types, like 'fifo',
   'socket' or even 'executable'.

 * common extension comparisons are bit faster, not using glob pattern
   matching but rather reusing code to find out last '.' and then
   comparing them in optimal way. I added E_FM2_SIMPLE_STRCASE_FILES
   to make it even faster if one wants, left disabled by now.




SVN revision: 39313
This commit is contained in:
Gustavo Sverzut Barbieri 2009-03-01 18:15:44 +00:00
parent 311291d19c
commit 82a8ab89df
2 changed files with 913 additions and 718 deletions

View File

@ -22861,6 +22861,11 @@ group { name: "e/icons/fileman/"NAME; \
}
EFMICON("folder","icon_efm_folder.png", 128)
EFMICON("chrdev","icon_efm_file.png", 128)
EFMICON("blkdev","icon_efm_file.png", 128)
EFMICON("fifo","icon_efm_file.png", 128)
EFMICON("socket","icon_efm_file.png", 128)
EFMICON("executable","icon_efm_file.png", 128)
EFMICON("file","icon_efm_file.png", 128)
EFMICON("home","icon_efm_home.png", 128)
EFMICON("root","icon_efm_root.png", 128)

File diff suppressed because it is too large Load Diff