Fix #989.
Improve popout window scaling animation by keeping it centered on the current position if possible.