Handle resize of window.