コード例 #1
0
        public Console()
        {
            InitializeComponent();
            config = new Configuration(this);
            oVPNWin = new OVPN(this);
            consoleTextBox.ReadOnly = true;
            consoleTB = consoleTextBox;
            connectedLabel = label2;
            ipLabel = label8;
            ipLabel.Text = "";

            this.KeyPreview = true;
            this.KeyDown += new KeyEventHandler(Console_KeyDown);
            this.connectedLabel.TextChanged += new EventHandler(ConnectedChanged);

            guardRules = new List<GuardRule>();

            ReadConfig();

            listBox2.DataSource = guardRules;
            defaultFWRules = GetFWRules();

            if (defaultPort != 0)
                portBox.Text = defaultPort.ToString();

            FindAndListService();
            notifyIcon1.Visible = false;
        }
コード例 #2
0
        public Console()
        {
            InitializeComponent();
            config  = new Configuration(this);
            oVPNWin = new OVPN(this);
            consoleTextBox.ReadOnly = true;
            consoleTB      = consoleTextBox;
            connectedLabel = label2;
            ipLabel        = label8;
            ipLabel.Text   = "";


            this.KeyPreview = true;
            this.KeyDown   += new KeyEventHandler(Console_KeyDown);
            this.connectedLabel.TextChanged += new EventHandler(ConnectedChanged);

            guardRules = new List <GuardRule>();

            ReadConfig();

            listBox2.DataSource = guardRules;
            defaultFWRules      = GetFWRules();

            if (defaultPort != 0)
            {
                portBox.Text = defaultPort.ToString();
            }

            FindAndListService();
            notifyIcon1.Visible = false;
        }