Example #1
0
        private void addMove_Click(object sender, RoutedEventArgs e)
        {
            AddOrChangeItem wnd = new AddOrChangeItem(this, currentlyShownUnit, "new_move");

            wnd.Show();
            moves.Items.Refresh();
        }
Example #2
0
        private void editItem_Click(object sender, RoutedEventArgs e)
        {
            var item = itemsList.SelectedItem as Item;

            if (item != null)
            {
                AddOrChangeItem wnd = new AddOrChangeItem(mainwindow, item, currentlyShownUnit);
                wnd.Show();
            }
        }
Example #3
0
        private void Button_Click_1(object sender, RoutedEventArgs e)
        {
            var crewMember = namesList.SelectedItem as Unit;
            var item       = memItems.SelectedItem as Item;

            if (crewMember != null && memItems.SelectedItem != null)
            {
                AddOrChangeItem form = new AddOrChangeItem(mainwindow, item, crewMember);
                form.ShowDialog();
            }
        }
Example #4
0
        private void editMove_Click(object sender, RoutedEventArgs e)
        {
            var move = moves.SelectedItem as Move;

            if (move != null)
            {
                AddOrChangeItem wnd = new AddOrChangeItem(this, move, currentlyShownUnit);
                delMove.IsEnabled = false; editMove.IsEnabled = false;
                wnd.Show();
            }
            moves.Items.Refresh();
        }
Example #5
0
        private void addItem_Click(object sender, RoutedEventArgs e)
        {
            AddOrChangeItem wnd = new AddOrChangeItem(this, currentlyShownUnit, "new_item");

            wnd.Show();
        }