Fixes for Haxe3.

The biggest one was had to change the bean.js & bean.min.js source
code to use "window" as the context, not "this".

Otherwise with Haxe 3's new "Modern" code output style it was throwing
an error, because "this" in that context is a relatively empty object
that is not what Bean is looking for...