Code cleanup (event bindings)

Moved all event bindings to document.ready 'cause that seems to make
sense.