using Panuon.WPF.UI;
using Plugin.TestResult_WPF.Model;
using System.Collections.ObjectModel;
namespace Plugin.TestResult_WPF
{
///
/// InfoWindow.xaml 的交互逻辑
///
public partial class InfoWindow : WindowX
{
private string _title;
public string title
{
get => _title;
set => Set(ref _title, value);
}
private ObservableCollection _dataSource;
public ObservableCollection dataSource
{
get => _dataSource == null ? new ObservableCollection() : _dataSource;
set => Set(ref _dataSource, value);
}
public InfoWindow(string title, ObservableCollection infos)
{
this.title = title;
this.dataSource = infos;
DataContext = this;
Topmost = false;
InitializeComponent();
}
public void UpdateSource(ObservableCollection infos)
{
this.dataSource = infos;
}
}
}