add window event bindings