Moved some code into AMD modules - updated window eventing library.