Remove window resize handler when leaving home page.