using System; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows; using System.Windows.Controls; using System.Windows.Data; using System.Windows.Documents; using System.Windows.Input; using System.Windows.Media; using System.Windows.Media.Imaging; using System.Windows.Shapes; namespace MvdLiteSnoop { /// /// Window1.xaml 的交互逻辑 /// public partial class Window1 : Window { public Window1() { DataContext = this; InitializeComponent(); } public List TypeList { get; set; } = new List { "TypeA", "TypeB", "TypeC" }; public ObservableCollection Items { get; set; } = new ObservableCollection { new RowItem { Name = "Item1", IsActive = true, Type = "TypeA" }, new RowItem { Name = "Item1", IsActive = true, Type = "TypeA" }, new RowItem { Name = "Item1", IsActive = true, Type = "TypeA" }, new RowItem { Name = "Item2", IsActive = false, Type = "TypeB" }, new RowItem { Name = "Item2", IsActive = false, Type = "TypeB" }, new RowItem { Name = "Item2", IsActive = false, Type = "TypeB" }, new RowItem { Name = "Item2", IsActive = false, Type = "TypeB" }, new RowItem { Name = "Item3", IsActive = true, Type = "TypeC" } }; } }