private void btnAdd_Click(object sender, RoutedEventArgs e) { string buildName = GetBuildName(Config.Instance.ShowCategories); if (!Config.Instance.ShowCategories && buildName == null) { return; } if (buildName == null) { buildName = ""; } TreeViewUtils.ClearTreeViewSelection(treeView); if (string.IsNullOrEmpty(buildName)) { buildName = "New Build"; } else { buildName += (buildName.Length == 0 || buildName.EndsWith("\\") ? "New Build" : "New"); } var edit = new EditWindow(buildName); edit.Show(); }
private void btnEdit_Click(object sender, RoutedEventArgs e) { string buildName = GetBuildName(); if (buildName != null) { TreeViewUtils.ClearTreeViewSelection(treeView); var edit = new EditWindow(buildName); edit.Show(); } }