made a toggle state for the ply/pause button