mirror of
https://github.com/ShareX/ShareX.git
synced 2024-09-30 01:07:21 +13:00
Support comparing two files
This commit is contained in:
parent
ced2b1253a
commit
03b2490858
1 changed files with 23 additions and 2 deletions
|
@ -122,12 +122,33 @@ private async void btnStartHashCheck_Click(object sender, EventArgs e)
|
|||
pbProgress.Value = 0;
|
||||
txtResult.Text = "";
|
||||
|
||||
string filePath = txtFilePath.Text;
|
||||
if (CompareTwoFiles)
|
||||
{
|
||||
txtTarget.Text = "";
|
||||
}
|
||||
|
||||
HashType hashType = (HashType)cbHashType.SelectedIndex;
|
||||
|
||||
string filePath = txtFilePath.Text;
|
||||
string result = await hashCheck.Start(filePath, hashType);
|
||||
|
||||
if (!string.IsNullOrEmpty(result))
|
||||
{
|
||||
txtResult.Text = result.ToUpperInvariant();
|
||||
|
||||
if (CompareTwoFiles)
|
||||
{
|
||||
string filePath2 = txtFilePath2.Text;
|
||||
string result2 = await hashCheck.Start(filePath2, hashType);
|
||||
|
||||
if (!string.IsNullOrEmpty(result2))
|
||||
{
|
||||
txtTarget.Text = result2.ToUpperInvariant();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
btnStartHashCheck.Text = Resources.Start;
|
||||
txtResult.Text = result?.ToUpperInvariant();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue