Better resize handling.