Allow to be notified when a quit is requested.