Added resize handler