private void listBoxItem_DoubleClick(object sender, MouseButtonEventArgs e)
 {
     this.NewContent = (sender as ListBoxItem).DataContext as NewContentAttribute;
     this.DialogResult = true;
 }
 private void Button_Click(object sender, System.Windows.RoutedEventArgs e)
 {
     this.NewContent = this.listView.SelectedItem as NewContentAttribute;
     this.DialogResult = true;
 }