New method to detect rotation in high-energy heavy-ion collisions