Fix rotation issue introduced in 1.5.2. Fix rotation issue on panning (issue #8).