New rotate-windows function.