adding redraw to resize event