added spacebar play/pause functionaliyt