private void AddExplorerLocationButton_Click(object sender, RoutedEventArgs e) { ExplorerLocation explorerLocation = new ExplorerLocation(); explorerLocation.ID = Guid.NewGuid(); ExplorerLocationForm explorerLocationForm = new ExplorerLocationForm(); explorerLocationForm.Initialize(Configuration.SiteSettings); explorerLocationForm.BindControls(explorerLocation); if (explorerLocationForm.ShowDialog(null, "New Explorer Location") == true) { Configuration.ExplorerConfiguration.ExplorerLocations.Add(explorerLocation); RefreshExplorerLocationsListBox(); } }
private void ExplorerLocationListBox_MouseDoubleClick(object sender, MouseButtonEventArgs e) { if (ExplorerLocationListBox.SelectedItem == null) { return; } ExplorerLocation explorerLocation = (ExplorerLocation)ExplorerLocationListBox.SelectedItem; ExplorerLocationForm explorerLocationForm = new ExplorerLocationForm(); explorerLocationForm.Initialize(Configuration.SiteSettings); explorerLocationForm.BindControls(explorerLocation); if (explorerLocationForm.ShowDialog(null, Languages.Translate("Edit Explorer Location")) == true) { RefreshExplorerLocationsListBox(); } }