using System.Collections.ObjectModel; using System.Reactive; using ReactiveUI; namespace Avalonia.UI.ViewModels; public class InformationCriminals : ViewModelBase { private bool _isBusy; private string? _searchText; public string? SearchText { get => _searchText; set => this.RaiseAndSetIfChanged(ref _searchText, value); } public bool IsBusy { get => _isBusy; set => this.RaiseAndSetIfChanged(ref _isBusy, value); } private VID? _selectedVID; public ObservableCollection SearchResults { get; } = new(); public VID? SelectedSomething { get => _selectedVID; set => this.RaiseAndSetIfChanged(ref _selectedVID, value); } public InformationCriminals() { SearchResults.Add(new VID()); SearchResults.Add(new VID()); SearchResults.Add(new VID()); } public ReactiveCommand BMCommand { get; } BMCommand = ReactiveCommand.Create(() => { return SelectedAlbum; }); }