private void DodajEfekt_Click(object sender, RoutedEventArgs e) { Effect newEfekt = new Effect(); EffectEditWindow efWnd = new EffectEditWindow(newEfekt, _helper); if (efWnd.ShowDialog() == true) { _character.Effects.Add(newEfekt); listView2.Items.Refresh(); } }
private void EdytujEfekt_Click(object sender, RoutedEventArgs e) { if (listView2.SelectedItem == null) { MessageBox.Show("Coś byś se wybrał najpierw"); return; } Effect efekt = (Effect)listView2.SelectedItem; EffectEditWindow efWnd = new EffectEditWindow(efekt, _helper); if (efWnd.ShowDialog() == true) { listView2.Items.Refresh(); } }