goldfire/howler.js — pull request #62 by alexdong (2013-07-06 05:57:00+00:00)
Title: Make `node.play` async when not using webAudio

It took me half day to figure out why Howler is not working in the latest Firefox release. If I manually load the `.ogg` file in the browser, Howler.play works beautifully but if the file is not loaded, there was no sound coming out.

By wrapping the `node.play` in a `setTimeout(func, 0)` wrapper, we force the `play` event to wait till the current loading event is finished.

Please note that Firefox's default setting for `media.webaudio.enabled` is `false`, which is why `self._webAudio` code path wasn't selected.