Fix resizing issues