Ejemplo n.º 1
0
        private void comboBoxEvent_SelectionChangeCommitted(object sender, EventArgs e)
        {
            Described <ServerEvent> selectedEvent = (Described <ServerEvent>)comboBoxEvent.SelectedItem;

            if (CurrentItem != null)
            {
                CurrentItem.Rule.ServerEvent = selectedEvent;
                UpdateItem(CurrentItem.Rule, listViewRules.SelectedItems[0]);
            }

            labelParameters.Text = ScriptFunctions.GetScript(selectedEvent);
        }
Ejemplo n.º 2
0
 private void SetEvent(ServerEvent serverEvent)
 {
     foreach (Described <ServerEvent> de in comboBoxEvent.Items)
     {
         if (de == serverEvent)
         {
             comboBoxEvent.SelectedItem = de;
             labelParameters.Text       = ScriptFunctions.GetScript(serverEvent);
             break;
         }
     }
 }