EliteBGS/UI/StationSuggestionProvider.cs

20 lines
569 B
C#
Raw Normal View History

using System.Collections;
using AutoCompleteTextBox.Editors;
2021-11-10 21:24:39 +01:00
using EliteBGS.EDDB;
2021-11-10 21:24:39 +01:00
namespace EliteBGS.UI {
public class StationSuggestionProvider : ISuggestionProvider {
private int system_id = 0;
private Stations stations = null;
public StationSuggestionProvider(Stations stations, int system_id) {
this.system_id = system_id;
this.stations = stations;
}
public IEnumerable GetSuggestions(string filter) {
return stations.StationNamesBySystemId(system_id, filter);
}
}
}