Fix onWindowOpen event handler.

The event handler was written for Firefox on Android, which is
slightly different.
Add README and LICENSE files.

Fixes issue #12.