Fixed buggy resize animation for top-level windows.