Improved handling of Firefox preferences and additional capabilities. Fixes #103 and #104