Note there is already a Theme Manager for Haiku that people can contribute to... http://dev.osdrawer.net/projects/thememanager (though you probably broke it with your changes, will have to check) François.
I'll check out that code and re-tool it. Probably not too much involved. Not sure if I'll have time today, but maybe tomorrow! --The loon