private void EditButton_Click(object sender, RoutedEventArgs e) { Note note = (sender as FrameworkElement).Tag as Note; note = App.Context.Notes.Include(n => n.NoteTags).ThenInclude(n => n.Tag).First(n => n.Key == note.Key); MainPage.CurrentNote = note; NoteEditor.SetState(NoteEditorState.Navigation); this.Frame.Navigate(typeof(NoteEditor), note); }
private void RelatedNotesGrid_DoubleTapped(object sender, DoubleTappedRoutedEventArgs e) { if (RelatedNotesListView.SelectedIndex >= 0) { NoteEditor.SetState(NoteEditorState.Navigation); MainPage.CurrentNote = RelatedNotesListView.SelectedItem as Note; this.Frame.Navigate(typeof(NoteEditor), RelatedNotesListView.SelectedItem as Note); } }