Fix handling of height when resized.