Exemplo n.º 1
0
        private async void editEntry(object sender, RoutedEventArgs e)
        {
            RecipeJournalEntry editingEntry  = (RecipeJournalEntry)((MenuFlyoutItem)e.OriginalSource).DataContext;
            JournalDialog      journalDialog = new JournalDialog(editingEntry);
            await journalDialog.ShowAsync();

            recipe.updateJournalEntry(journalDialog.NewEntry);
        }
Exemplo n.º 2
0
        private async void showJournalDialog(object sender, RoutedEventArgs e)
        {
            JournalDialog journalDialog = new JournalDialog();
            await journalDialog.ShowAsync();

            if (journalDialog.NewEntry != null)
            {
                journalDialog.NewEntry.RecipeID = recipe.ID;
                recipe.addJournalEntry(journalDialog.NewEntry);
            }
        }