Add a listener on a PanEvent.
A lambda that takes a PanEvent and will be called each time a PanEvent occurs.