public ProxySwitcherForm() { InitializeComponent(); proxyRegistry = new ProxyRegistry(); UpdateButtonStyle(); }
private void FormMain_Load(object sender, EventArgs e) { registry = new ProxyRegistry(); isProxyEnable = registry.ProxyEnable; registry.GetProxyServer(ref proxyAddress, ref proxyPort); registry.GetProxyOverride(ref proxyExceptions, ref bypassLocal); monitor = new RegistryMonitor(registry.Key); monitor.RegChanged += Monitor_RegChanged; monitor.Start(); }