Added event binders to window and document