2021-07-09 14:40:27 +02:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections;
|
|
|
|
|
using AutoCompleteTextBox.Editors;
|
2021-11-10 21:24:39 +01:00
|
|
|
|
using EliteBGS.EDDB;
|
2021-07-09 14:40:27 +02:00
|
|
|
|
|
2021-11-10 21:24:39 +01:00
|
|
|
|
namespace EliteBGS.UI {
|
2021-07-09 14:40:27 +02:00
|
|
|
|
public class SystemSuggestionProvider : ISuggestionProvider {
|
|
|
|
|
private PopulatedSystems systems = null;
|
|
|
|
|
|
|
|
|
|
public SystemSuggestionProvider(PopulatedSystems systems) {
|
|
|
|
|
this.systems = systems;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public PopulatedSystems Data {
|
|
|
|
|
get => systems;
|
|
|
|
|
set => systems = value;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public IEnumerable GetSuggestions(string filter) {
|
|
|
|
|
return systems.SystemNamesByFilter(filter);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|