Пример #1
0
        private void MenuItem_Click_ContactsAddToGroup(object sender, RoutedEventArgs e)
        {
            TreeViewItem      selectedTreeViewItem = treeView.SelectedItem as TreeViewItem;
            Person            selectedPerson       = selectedTreeViewItem.Tag as Person;
            TreeViewItem      parentTreeViewItem   = selectedTreeViewItem.Parent as TreeViewItem;
            Group             curGroup             = parentTreeViewItem.Tag as Group;
            ModifyGroupWindow modifyGroupWindow    = new ModifyGroupWindow(ref services, ref curGroup, ref selectedPerson, ModifyGroupMode.Add);

            modifyGroupWindow.ShowDialog();
            LoadData(services.GetGroups());
        }
Пример #2
0
 private void MenuItem_Click_ContactsAddToGroup(object sender, RoutedEventArgs e)
 {
     TreeViewItem selectedTreeViewItem = treeView.SelectedItem as TreeViewItem;
     Person selectedPerson = selectedTreeViewItem.Tag as Person;
     TreeViewItem parentTreeViewItem = selectedTreeViewItem.Parent as TreeViewItem;
     Group curGroup = parentTreeViewItem.Tag as Group;
     ModifyGroupWindow modifyGroupWindow = new ModifyGroupWindow(ref services, ref curGroup, ref selectedPerson, ModifyGroupMode.Add);
     modifyGroupWindow.ShowDialog();
     LoadData(services.GetGroups());
 }