Rework panning to play nice with zooming.