public MusicStoreViewModel() { this.WhenAnyValue(x => x.SearchText) .Where(x => !string.IsNullOrWhiteSpace(x)) .Throttle(TimeSpan.FromMilliseconds(400)) .ObserveOn(RxApp.MainThreadScheduler) .Subscribe(DoSearch !); BuyMusicCommand = ReactiveCommand.CreateFromTask(async() => { if (SelectedAlbum is { }) { await SelectedAlbum.SaveToDiskAsync(); return(SelectedAlbum); } return(null); });
private void Menu_Photo_Delete_Click(object sender, RoutedEventArgs e) { SelectedAlbum.DeleteSelectedPhotos(); }
private void Menu_Photo_Details_Click(object sender, RoutedEventArgs e) { SelectedAlbum.ShowSelectedPhotoDetails(); }
private void Menu_Capture_Click(object sender, RoutedEventArgs e) { SelectedAlbum.Capture(); }
private void Menu_AddPhotos_Click(object sender, RoutedEventArgs e) { SelectedAlbum.AddPhotosFromStorage(); }
internal void Cancel() { SelectedAlbum.RejectChanges(); }
internal void Apply() { SelectedAlbum.AcceptChanges(); }