mirror of
https://github.com/mRemoteNG/mRemoteNG.git
synced 2026-02-17 22:11:48 +08:00
pass config file name to password form on startup, fixes #1720
This commit is contained in:
@@ -33,7 +33,7 @@ namespace mRemoteNG.Config.Connections
|
||||
|
||||
private Optional<SecureString> PromptForPassword()
|
||||
{
|
||||
var password = MiscTools.PasswordDialog("", false);
|
||||
var password = MiscTools.PasswordDialog(Path.GetFileName(_connectionFilePath), false);
|
||||
return password;
|
||||
}
|
||||
}
|
||||
|
||||
10
mRemoteV1/UI/Forms/PasswordForm.Designer.cs
generated
10
mRemoteV1/UI/Forms/PasswordForm.Designer.cs
generated
@@ -77,7 +77,7 @@ namespace mRemoteNG.UI.Forms
|
||||
this.btnOK.TabIndex = 7;
|
||||
this.btnOK.Text = global::mRemoteNG.Language.strButtonOK;
|
||||
this.btnOK.UseVisualStyleBackColor = true;
|
||||
this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
|
||||
this.btnOK.Click += new System.EventHandler(this.BtnOK_Click);
|
||||
//
|
||||
// btnCancel
|
||||
//
|
||||
@@ -90,7 +90,7 @@ namespace mRemoteNG.UI.Forms
|
||||
this.btnCancel.TabIndex = 6;
|
||||
this.btnCancel.Text = global::mRemoteNG.Language.strButtonCancel;
|
||||
this.btnCancel.UseVisualStyleBackColor = true;
|
||||
this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click);
|
||||
this.btnCancel.Click += new System.EventHandler(this.BtnCancel_Click);
|
||||
//
|
||||
// lblStatus
|
||||
//
|
||||
@@ -128,7 +128,7 @@ namespace mRemoteNG.UI.Forms
|
||||
this.txtVerify.Size = new System.Drawing.Size(298, 22);
|
||||
this.txtVerify.TabIndex = 4;
|
||||
this.txtVerify.UseSystemPasswordChar = true;
|
||||
this.txtVerify.TextChanged += new System.EventHandler(this.txtPassword_TextChanged);
|
||||
this.txtVerify.TextChanged += new System.EventHandler(this.TxtPassword_TextChanged);
|
||||
//
|
||||
// txtPassword
|
||||
//
|
||||
@@ -141,7 +141,7 @@ namespace mRemoteNG.UI.Forms
|
||||
this.txtPassword.Size = new System.Drawing.Size(298, 22);
|
||||
this.txtPassword.TabIndex = 2;
|
||||
this.txtPassword.UseSystemPasswordChar = true;
|
||||
this.txtPassword.TextChanged += new System.EventHandler(this.txtPassword_TextChanged);
|
||||
this.txtPassword.TextChanged += new System.EventHandler(this.TxtPassword_TextChanged);
|
||||
//
|
||||
// tableLayoutPanel1
|
||||
//
|
||||
@@ -190,7 +190,7 @@ namespace mRemoteNG.UI.Forms
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
||||
this.Text = "Password";
|
||||
this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.PasswordForm_FormClosed);
|
||||
this.Load += new System.EventHandler(this.frmPassword_Load);
|
||||
this.Load += new System.EventHandler(this.FrmPassword_Load);
|
||||
((System.ComponentModel.ISupportInitialize)(this.pbLock)).EndInit();
|
||||
this.tableLayoutPanel1.ResumeLayout(false);
|
||||
this.tableLayoutPanel1.PerformLayout();
|
||||
|
||||
@@ -50,7 +50,7 @@ namespace mRemoteNG.UI.Forms
|
||||
|
||||
#region Event Handlers
|
||||
|
||||
private void frmPassword_Load(object sender, EventArgs e)
|
||||
private void FrmPassword_Load(object sender, EventArgs e)
|
||||
{
|
||||
ApplyLanguage();
|
||||
ApplyTheme();
|
||||
@@ -70,13 +70,13 @@ namespace mRemoteNG.UI.Forms
|
||||
txtVerify.Text = "";
|
||||
}
|
||||
|
||||
private void btnCancel_Click(object sender, EventArgs e)
|
||||
private void BtnCancel_Click(object sender, EventArgs e)
|
||||
{
|
||||
DialogResult = DialogResult.Cancel;
|
||||
Close();
|
||||
}
|
||||
|
||||
private void btnOK_Click(object sender, EventArgs e)
|
||||
private void BtnOK_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (NewPasswordMode)
|
||||
VerifyNewPassword();
|
||||
@@ -84,7 +84,7 @@ namespace mRemoteNG.UI.Forms
|
||||
DialogResult = DialogResult.OK;
|
||||
}
|
||||
|
||||
private void txtPassword_TextChanged(object sender, EventArgs e)
|
||||
private void TxtPassword_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
HideStatus();
|
||||
}
|
||||
|
||||
@@ -1562,6 +1562,7 @@
|
||||
<ItemGroup>
|
||||
<Reference Include="mscorlib" />
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Web" />
|
||||
<Reference Include="VncSharp">
|
||||
<HintPath>References\VncSharp.dll</HintPath>
|
||||
|
||||
Reference in New Issue
Block a user