Mozilla, Chrome and FUEL

I wrote an XSPF import handler for Songbird yesterday, before noticing that someone else had already mostly done it. Still, the code might be useful if you ever need to open an XML file and parse it using E4X within an XULRunner application.

The code probably works the same from within a Firefox extension as well, but there are still times where it takes trial and error to find out which commands work in which circumstances. The FUEL library is a good start at making things easier for Firefox extension and XULRunner developers, but doesn't cover enough yet.

For example, there's still a lot of confusion about how to call these:

There are also lots of helper functions that would be useful, such as
which could replace

It's that last kind of incantation that makes building Firefox extensions and XUL applications much harder than it needs to be.