void btnDelete_Click(object sender, DeleteStringListItemRoutedEventArgs e) { var itm = sender as StringListItemControl; var e2 = new StringListItemRoutedEventArgs(RemovedItemEvent); e2.Item = _items[(int)e.Id]; RemoveListItem(itm, e.Id); RaiseEvent(e2); }
private void AddItem_Click(object sender, RoutedEventArgs e) { var e2 = new StringListItemRoutedEventArgs(AddItemEvent); RaiseEvent(e2); if (e2.Handled) { AddListItem(e2.Item); var e3 = new StringListItemRoutedEventArgs(AddedItemEvent); e3.Item = e2.Item; RaiseEvent(e3); } }
private void AddItem_Click(object sender, RoutedEventArgs e) { var e2 = new StringListItemRoutedEventArgs(AddItemEvent); RaiseEvent(e2); if( e2.Handled ) { AddListItem(e2.Item); var e3 = new StringListItemRoutedEventArgs(AddedItemEvent); e3.Item = e2.Item; RaiseEvent(e3); } }
private void asmPaths_RemovedItem(object sender, StringListItemRoutedEventArgs e) { UpdateSendCommandInfo(); }
private void asmPaths_AddItem(object sender, StringListItemRoutedEventArgs e) { VistaFolderBrowserDialog dialog = new VistaFolderBrowserDialog(); dialog.Description = "Please select Command Assembly Folder"; dialog.UseDescriptionForTitle = true; if( (bool)dialog.ShowDialog(this) ) { e.Item = dialog.SelectedPath; e.Handled = true; } }
private void asmPaths_AddedItem(object sender, StringListItemRoutedEventArgs e) { // Work-around due Resolve Assemblies use Config.Servers for Paths, when spec. Cmd Definition var s = _config.Servers.Single(sv => sv.Name == cbServers.SelectedValue as string); s.CommandsAssemblyPaths = asmPaths.GetItems(); UpdateSendCommandInfo(); }
private void queue_RemovedItem(object sender, StringListItemRoutedEventArgs e) { UpdateQueueuInfo(); }
private void Queue_AddItem_1(object sender, StringListItemRoutedEventArgs e) { StringListControl s = sender as StringListControl; SelectQueueDialog dlg = new SelectQueueDialog(_sys, cbServers.SelectedValue as string, GetAllQueueNames().Except(s.GetItems().ToList()).ToArray()); dlg.Title = "Select " + s.Title.Remove(s.Title.Length - 1); dlg.Owner = this; if( dlg.ShowDialog() == true ) { e.Handled = true; e.Item = dlg.SelectedQueueName; } }