コード例 #1
0
ファイル: AddEditMacRule.cs プロジェクト: zzz654321/fireBwall
        // 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;
        }
コード例 #2
0
 public MacFilterControl(MacFilterModule mf)
 {
     this.mf = mf;
     InitializeComponent();
 }
コード例 #3
0
 public MacFilterControl(MacFilterModule mf)
 {
     this.mf = mf;
     InitializeComponent();
 }