private async void ApplySetting() { try { var type = (FEnv.FurnishType)FurnishingItemTypePicker.SelectedIndex; var note = FurnishingItemNoteEntry.Text; var manager = notiManager as FurnishingNotiManager; if (editType == NotiManager.EditType.Add) { Noti = new FurnishingNoti(type); } else if (editType == NotiManager.EditType.Edit) { Noti.EditItemType(type); } Noti.ItemNote = note; manager.EditList(Noti, editType); await Navigation.PopAsync(); } catch { } }
public EditFurnishingItemPage(NotiManager notiManager, NotiManager.EditType type, FurnishingNoti noti = null) { editType = type; this.notiManager = notiManager; Noti = noti; InitializeComponent(); Title = (editType == NotiManager.EditType.Add) ? AppResources.EditItemPage_Title_New : AppResources.EditItemPage_Title_Edit; InitPicker(); }
private void FurnishingSpeedUpToolbarItem_Clicked(object sender, EventArgs e) { if (ListView.SelectedItems.Count < 0) { return; } FurnishingNoti selectedNoti = (FurnishingNoti)ListView.SelectedItem; selectedNoti.NotiTime = selectedNoti.NotiTime.AddHours(-FEnv.SpeedUpHour); NotiManager.EditList(selectedNoti, NotiManager.EditType.EditOnlyTime); Utils.RefreshCollectionView(ListView, Notis); }