Beispiel #1
0
        private void AddClasse_Click(object sender, RoutedEventArgs e)
        {
            var wind = new AddClass {
                Owner = Window.GetWindow(this)
            };

            wind.ShowDialog();
            Refresh();
        }
Beispiel #2
0
        private void ClassContextMod_OnClick(object sender, RoutedEventArgs e)
        {
            var menuItem = (MenuItem)e.Source;
            var menu     = (ContextMenu)menuItem.Parent;
            var list     = (ListBox)menu.PlacementTarget;

            if (list?.SelectedValue == null)
            {
                return;
            }

            var wind = new AddClass(App.DataS.Pedagogy.Classes.GetClasseById(new Guid(list.SelectedValue.ToString())))
            {
                Owner = Window.GetWindow(this)
            };

            wind.ShowDialog();
            Refresh();
        }