added key events ('s', 'r' and 'p')