I have been looking for a X-browser way to do this myself and the best I cam up with so far was to ping google.com with a XHR OPTIONS type request. Pretty ugly, but it works.
If the resource can't be pinged, it means either the user is offline or the app is down which are essentially the same thing for your app in most cases, while in your implementation, it could just mean Google.com is down (There is very low chance of this happening. Still..)
EDIT: Made the second paragraph clearer.
Could be a change in FF, difference in os's, or something in the library. Not a very helpful comment I'm afraid.
* Worked after I relaunched Chrome and updated to 23.0.1271.64