fixes autopan of popups with images