Exemple #1
0
 private void cancel_btn_Click(object sender, RoutedEventArgs e)
 {
     this.DialogResult = false;
     // Delete token if mode is Create and token is defined
     if (profileToken != null && isCreateMode)
     {
         media.DeleteProfile(profileToken);
     }
     this.Close();
 }
 private void delete_profile_btn_Click(object sender, RoutedEventArgs e)
 {
     // Remove selected profile
     if (listBox.SelectedIndex >= 0)
     {
         media.DeleteProfile(profiles[listBox.SelectedIndex].token);
         profiles = media.GetProfiles(null, null);
         refreshProfileList();
         textBox.Text = "";
     }
 }