Change this & window reference to a `global` passed in closure

closes #2413

Use global inside closures to improve obfuscation and prepare for the future.

P.S.: A bit scary to change so many references... 
I ran the specs on this and [got all green](https://travis-ci.org/SergioCrisostomo/mootools-core/builds/29363119), still would be nice with some pair human eyes looking at the changes...