handling rotation when zooming