Ejemplo n.º 1
0
 /// <summary>
 /// Edit in new window. Just because i can :).
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void MenuItem_Click(object sender, RoutedEventArgs e)
 {
     if (foodDataGrid.SelectedItem != null)
     {
         Food           temp = (Food)foodDataGrid.SelectedItem;
         EditFoodWindow win  = new EditFoodWindow(temp, this);
         win.ShowDialog();
     }
 }
Ejemplo n.º 2
0
 //Edit window from foodsearch window
 private void MenuItem_Click(object sender, RoutedEventArgs e)
 {
     if (dgFoods.SelectedItem != null)
     {
         Food           temp = (Food)dgFoods.SelectedItem;
         EditFoodWindow win  = new EditFoodWindow(temp, _window);
         win.ShowDialog();
     }
 }