1
0
mirror of https://github.com/Ylianst/MeshCentralRouter synced 2026-01-19 16:23:14 +00:00

Manual proxy improvements.

This commit is contained in:
Ylian Saint-Hilaire
2022-05-19 00:14:23 -07:00
parent b8f14536fb
commit bafc19f99f
12 changed files with 3352 additions and 1021 deletions

View File

@@ -28,167 +28,221 @@
/// </summary>
private void InitializeComponent()
{
this.SaveProxyConfig = new System.Windows.Forms.Button();
this.manualHttpProxyHost = new System.Windows.Forms.TextBox();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ProxySettings));
this.okButton = new System.Windows.Forms.Button();
this.hostTextBox = new System.Windows.Forms.TextBox();
this.label1 = new System.Windows.Forms.Label();
this.manualHttpProxyPort = new System.Windows.Forms.TextBox();
this.label2 = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this.manualHttpProxyUsername = new System.Windows.Forms.TextBox();
this.usernameTextBox = new System.Windows.Forms.TextBox();
this.label4 = new System.Windows.Forms.Label();
this.manualHttpProxyPassword = new System.Windows.Forms.TextBox();
this.passwordTextBox = new System.Windows.Forms.TextBox();
this.label5 = new System.Windows.Forms.Label();
this.useManualProxySettings = new System.Windows.Forms.CheckBox();
this.cancel = new System.Windows.Forms.Button();
this.manualProxyCheckBox = new System.Windows.Forms.CheckBox();
this.cancelButton = new System.Windows.Forms.Button();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.label2 = new System.Windows.Forms.Label();
this.authComboBox = new System.Windows.Forms.ComboBox();
this.groupBox1.SuspendLayout();
this.SuspendLayout();
//
// SaveProxyConfig
// okButton
//
this.SaveProxyConfig.Location = new System.Drawing.Point(124, 404);
this.SaveProxyConfig.Name = "SaveProxyConfig";
this.SaveProxyConfig.Size = new System.Drawing.Size(75, 23);
this.SaveProxyConfig.TabIndex = 1;
this.SaveProxyConfig.Text = "Ok";
this.SaveProxyConfig.UseVisualStyleBackColor = true;
this.SaveProxyConfig.Click += new System.EventHandler(this.SaveProxyConfig_Click);
this.okButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.okButton.Location = new System.Drawing.Point(164, 203);
this.okButton.Margin = new System.Windows.Forms.Padding(2);
this.okButton.Name = "okButton";
this.okButton.Size = new System.Drawing.Size(95, 23);
this.okButton.TabIndex = 1;
this.okButton.Text = "OK";
this.okButton.UseVisualStyleBackColor = true;
this.okButton.Click += new System.EventHandler(this.okButton_Click);
//
// manualHttpProxyHost
// hostTextBox
//
this.manualHttpProxyHost.Location = new System.Drawing.Point(104, 141);
this.manualHttpProxyHost.Name = "manualHttpProxyHost";
this.manualHttpProxyHost.Size = new System.Drawing.Size(203, 22);
this.manualHttpProxyHost.TabIndex = 2;
this.hostTextBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.hostTextBox.Location = new System.Drawing.Point(145, 39);
this.hostTextBox.Margin = new System.Windows.Forms.Padding(2);
this.hostTextBox.Name = "hostTextBox";
this.hostTextBox.Size = new System.Drawing.Size(192, 20);
this.hostTextBox.TabIndex = 2;
this.hostTextBox.TextChanged += new System.EventHandler(this.manualProxyCheckBox_CheckedChanged);
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(75, 114);
this.label1.Location = new System.Drawing.Point(6, 42);
this.label1.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(103, 17);
this.label1.Size = new System.Drawing.Size(106, 13);
this.label1.TabIndex = 3;
this.label1.Text = "Http proxy host";
this.label1.Click += new System.EventHandler(this.label1_Click);
//
// manualHttpProxyPort
//
this.manualHttpProxyPort.Location = new System.Drawing.Point(104, 208);
this.manualHttpProxyPort.Name = "manualHttpProxyPort";
this.manualHttpProxyPort.Size = new System.Drawing.Size(203, 22);
this.manualHttpProxyPort.TabIndex = 4;
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(75, 181);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(101, 17);
this.label2.TabIndex = 5;
this.label2.Text = "Http proxy port";
this.label1.Text = "Proxy Hostname:Port";
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(75, 257);
this.label3.Location = new System.Drawing.Point(5, 93);
this.label3.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(139, 17);
this.label3.Size = new System.Drawing.Size(55, 13);
this.label3.TabIndex = 7;
this.label3.Text = "Http proxy username";
this.label3.Text = "Username";
//
// manualHttpProxyUsername
// usernameTextBox
//
this.manualHttpProxyUsername.Location = new System.Drawing.Point(104, 286);
this.manualHttpProxyUsername.Name = "manualHttpProxyUsername";
this.manualHttpProxyUsername.Size = new System.Drawing.Size(203, 22);
this.manualHttpProxyUsername.TabIndex = 6;
this.usernameTextBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.usernameTextBox.Location = new System.Drawing.Point(145, 90);
this.usernameTextBox.Margin = new System.Windows.Forms.Padding(2);
this.usernameTextBox.Name = "usernameTextBox";
this.usernameTextBox.Size = new System.Drawing.Size(192, 20);
this.usernameTextBox.TabIndex = 6;
this.usernameTextBox.TextChanged += new System.EventHandler(this.manualProxyCheckBox_CheckedChanged);
//
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(78, 332);
this.label4.Location = new System.Drawing.Point(6, 117);
this.label4.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(136, 17);
this.label4.Size = new System.Drawing.Size(53, 13);
this.label4.TabIndex = 9;
this.label4.Text = "Http proxy password";
this.label4.Text = "Password";
//
// manualHttpProxyPassword
// passwordTextBox
//
this.manualHttpProxyPassword.Location = new System.Drawing.Point(104, 362);
this.manualHttpProxyPassword.Name = "manualHttpProxyPassword";
this.manualHttpProxyPassword.PasswordChar = '*';
this.manualHttpProxyPassword.Size = new System.Drawing.Size(203, 22);
this.manualHttpProxyPassword.TabIndex = 8;
this.passwordTextBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.passwordTextBox.Location = new System.Drawing.Point(145, 114);
this.passwordTextBox.Margin = new System.Windows.Forms.Padding(2);
this.passwordTextBox.Name = "passwordTextBox";
this.passwordTextBox.PasswordChar = '*';
this.passwordTextBox.Size = new System.Drawing.Size(192, 20);
this.passwordTextBox.TabIndex = 8;
this.passwordTextBox.TextChanged += new System.EventHandler(this.manualProxyCheckBox_CheckedChanged);
//
// label5
//
this.label5.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.label5.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label5.Location = new System.Drawing.Point(13, 9);
this.label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label5.Location = new System.Drawing.Point(12, 7);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(396, 69);
this.label5.Size = new System.Drawing.Size(346, 44);
this.label5.TabIndex = 10;
this.label5.Text = "Manually configure an HTTP proxy server to use. Username and password are optiona" +
"l. Only basic auth is supported.";
this.label5.Text = "By default, the system\'s proxy is used. You can override this by manually configu" +
"ring your own proxy settings here.\r\n";
this.label5.UseMnemonic = false;
//
// useManualProxySettings
// manualProxyCheckBox
//
this.useManualProxySettings.AutoSize = true;
this.useManualProxySettings.Location = new System.Drawing.Point(43, 81);
this.useManualProxySettings.Name = "useManualProxySettings";
this.useManualProxySettings.Size = new System.Drawing.Size(194, 21);
this.useManualProxySettings.TabIndex = 11;
this.useManualProxySettings.Text = "use manual proxy settings";
this.useManualProxySettings.UseVisualStyleBackColor = true;
this.useManualProxySettings.CheckedChanged += new System.EventHandler(this.useManualProxySettings_CheckedChanged);
this.manualProxyCheckBox.AutoSize = true;
this.manualProxyCheckBox.Location = new System.Drawing.Point(145, 18);
this.manualProxyCheckBox.Margin = new System.Windows.Forms.Padding(2);
this.manualProxyCheckBox.Name = "manualProxyCheckBox";
this.manualProxyCheckBox.Size = new System.Drawing.Size(131, 17);
this.manualProxyCheckBox.TabIndex = 11;
this.manualProxyCheckBox.Text = "Manual Proxy Settings";
this.manualProxyCheckBox.UseVisualStyleBackColor = true;
this.manualProxyCheckBox.CheckedChanged += new System.EventHandler(this.manualProxyCheckBox_CheckedChanged);
//
// cancel
// cancelButton
//
this.cancel.Location = new System.Drawing.Point(232, 404);
this.cancel.Name = "cancel";
this.cancel.Size = new System.Drawing.Size(75, 23);
this.cancel.TabIndex = 12;
this.cancel.Text = "Cancel";
this.cancel.UseVisualStyleBackColor = true;
this.cancel.Click += new System.EventHandler(this.cancel_Click);
this.cancelButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.cancelButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.cancelButton.Location = new System.Drawing.Point(263, 203);
this.cancelButton.Margin = new System.Windows.Forms.Padding(2);
this.cancelButton.Name = "cancelButton";
this.cancelButton.Size = new System.Drawing.Size(95, 23);
this.cancelButton.TabIndex = 12;
this.cancelButton.Text = "Cancel";
this.cancelButton.UseVisualStyleBackColor = true;
this.cancelButton.Click += new System.EventHandler(this.cancelButton_Click);
//
// groupBox1
//
this.groupBox1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.groupBox1.Controls.Add(this.label2);
this.groupBox1.Controls.Add(this.authComboBox);
this.groupBox1.Controls.Add(this.hostTextBox);
this.groupBox1.Controls.Add(this.usernameTextBox);
this.groupBox1.Controls.Add(this.manualProxyCheckBox);
this.groupBox1.Controls.Add(this.passwordTextBox);
this.groupBox1.Controls.Add(this.label4);
this.groupBox1.Controls.Add(this.label1);
this.groupBox1.Controls.Add(this.label3);
this.groupBox1.Location = new System.Drawing.Point(12, 54);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(342, 144);
this.groupBox1.TabIndex = 13;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "Proxy Settings";
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(6, 67);
this.label2.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(104, 13);
this.label2.TabIndex = 13;
this.label2.Text = "Proxy Authentication";
//
// authComboBox
//
this.authComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.authComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.authComboBox.FormattingEnabled = true;
this.authComboBox.Items.AddRange(new object[] {
"None",
"Basic Authentication"});
this.authComboBox.Location = new System.Drawing.Point(145, 64);
this.authComboBox.Name = "authComboBox";
this.authComboBox.Size = new System.Drawing.Size(192, 21);
this.authComboBox.TabIndex = 12;
this.authComboBox.SelectedIndexChanged += new System.EventHandler(this.manualProxyCheckBox_CheckedChanged);
//
// ProxySettings
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
this.AcceptButton = this.okButton;
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(482, 450);
this.Controls.Add(this.cancel);
this.Controls.Add(this.useManualProxySettings);
this.CancelButton = this.cancelButton;
this.ClientSize = new System.Drawing.Size(369, 237);
this.Controls.Add(this.groupBox1);
this.Controls.Add(this.cancelButton);
this.Controls.Add(this.label5);
this.Controls.Add(this.label4);
this.Controls.Add(this.manualHttpProxyPassword);
this.Controls.Add(this.label3);
this.Controls.Add(this.manualHttpProxyUsername);
this.Controls.Add(this.label2);
this.Controls.Add(this.manualHttpProxyPort);
this.Controls.Add(this.label1);
this.Controls.Add(this.manualHttpProxyHost);
this.Controls.Add(this.SaveProxyConfig);
this.Controls.Add(this.okButton);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Margin = new System.Windows.Forms.Padding(2);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "ProxySettings";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.Text = "Proxy Settings";
this.groupBox1.ResumeLayout(false);
this.groupBox1.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Button SaveProxyConfig;
private System.Windows.Forms.TextBox manualHttpProxyHost;
private System.Windows.Forms.Button okButton;
private System.Windows.Forms.TextBox hostTextBox;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox manualHttpProxyPort;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox manualHttpProxyUsername;
private System.Windows.Forms.TextBox usernameTextBox;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.TextBox manualHttpProxyPassword;
private System.Windows.Forms.TextBox passwordTextBox;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.CheckBox useManualProxySettings;
private System.Windows.Forms.Button cancel;
private System.Windows.Forms.CheckBox manualProxyCheckBox;
private System.Windows.Forms.Button cancelButton;
private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.ComboBox authComboBox;
}
}