fix resize event to be on window.