Factor out a Selection class to manage a selected region of the map.