Box 1.6

Changed document event listener to window.