Window animation fix