Fix Resize bugs.