Example #1
0
        private void Dodaj_Click(object sender, RoutedEventArgs e)
        {
            _Class_List.SelectedIndex = -1;
            ClassWindow _ClassWindow = new ClassWindow();

            //   _ClassWindow.Owner = this;
            _ClassWindow.ShowDialog();
            if (_ClassWindow.DialogResult == true)
            {
                Classes.Add(_ClassWindow.MainClassObject);
                //Dalej wpisac na liste
            }
            _Class_List.Items.Refresh();
        }
Example #2
0
        private void Edytuj_Click(object sender, RoutedEventArgs e)
        {
            ClassWindow _ClassWindow = new ClassWindow();

            //   _ClassWindow.Owner = this;
            if (_Class_List.SelectedIndex != -1)
            {
                _ClassWindow.ShowDialog();
            }
            if (_ClassWindow.DialogResult == true)
            {
                Classes[_Class_List.SelectedIndex] = _ClassWindow.MainClassObject;
                //Dalej wpisac na liste
            }
            _Class_List.Items.Refresh();
            Preview_TextBox.Text = Classes[_Class_List.SelectedIndex].ToFinalString();
        }