Files
FSI.BT.IR.Tools/FSI.BT.Tools/RadialMenu/CmdProvider.cs
Maier Stephan SI b684704bf8 Sicherung
2023-01-20 16:09:00 +01:00

27 lines
681 B
C#

using AutoCompleteTextBox.Editors;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace FSI.BT.Tools.RadialMenu
{
public class CmdProvider : ISuggestionProvider
{
private readonly ObservableCollection<string> _cmds;
public IEnumerable GetSuggestions(string filter)
{
return _cmds.Where(x => x.StartsWith(filter, StringComparison.InvariantCultureIgnoreCase));
}
public CmdProvider(ref ObservableCollection<string> cmds)
{
this._cmds = cmds;
}
}
}