// overloaded constructor for editing an existing rule public AddEditMacRule(MacFilterModule.MacRule RULE) { InitializeComponent(); // set the in/out boxes if ((RULE.direction & MacFilterModule.Direction.IN) != 0 ) checkBoxIn.Checked = true; if ((RULE.direction & MacFilterModule.Direction.OUT) != 0 ) checkBoxOut.Checked = true; // set the MAC if (!String.IsNullOrEmpty(RULE.mac.ToString())) { textBoxArguments.Text = new PhysicalAddress(RULE.mac).ToString(); } // set logging checkBoxLog.Checked = RULE.log; // set the status if ((RULE.ps & MacFilterModule.PacketStatus.ALLOWED) != 0) comboBoxAction.SelectedIndex = 1; else comboBoxAction.SelectedIndex = 0; //notify notifyBox.Checked = RULE.notify; }
public MacFilterControl(MacFilterModule mf) { this.mf = mf; InitializeComponent(); }
public MacFilterControl(MacFilterModule mf) { this.mf = mf; InitializeComponent(); }