From 5a0c6d8c6a621338e7b313ca872870f9eb3a0171 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miskolczi=20Rich=C3=A1rd?= Date: Sun, 2 Apr 2023 22:49:06 +0200 Subject: [PATCH] Using Common --- GUI/MainForm.cs | 12 +++++++----- .../GUI.csproj.AssemblyReference.cache | Bin 107527 -> 108505 bytes 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/GUI/MainForm.cs b/GUI/MainForm.cs index 25ecbfc..1ca5644 100644 --- a/GUI/MainForm.cs +++ b/GUI/MainForm.cs @@ -1,3 +1,5 @@ +using Common; + namespace GUI; sealed public partial class MainForm : Form @@ -43,8 +45,8 @@ sealed public partial class MainForm : Form Close(); } - private void CopyAndNotify(string? line, string fileName) - { + private void CopyAndNotify(string? line, string fileName) + { ProcessBuilder pb = new ProcessBuilder(); pb.ProcessFailed += (e) => MessageBox.Show(e.ToString(), "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); if (line != null) @@ -56,13 +58,13 @@ sealed public partial class MainForm : Form { pb.Run("./ToastNotification.exe", "\"Error\" \"No password copied\""); } - } + } private void Decrypt(object sender, EventArgs e) { ProcessBuilder pb = new ProcessBuilder(); - pb.ProcessFailed += (e) => MessageBox.Show(e.ToString(), "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); - CopyAndNotify(pb.GetOutput("gpg.exe", $"--quiet --decrypt {PathRequest()}\\{ResultList.Text}"), ResultList.Text); + pb.ProcessFailed += (e) => MessageBox.Show(e.ToString(), "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); + CopyAndNotify(pb.GetOutput("gpg.exe", $"--quiet --decrypt {PathRequest()}\\{ResultList.Text}"), ResultList.Text); Close(); } } diff --git a/GUI/obj/Debug/net7.0-windows/GUI.csproj.AssemblyReference.cache b/GUI/obj/Debug/net7.0-windows/GUI.csproj.AssemblyReference.cache index 1ca95f0141b402885322fa09d4571cdf8f0f279a..1d778e31a0af5af96d770de798cf7637c1d69187 100644 GIT binary patch delta 761 zcmZoa!FKaJ8wVTX9tH*m#@NY%LY~t<7O*f-1{qB6mt~N@Gbhzb zUtizZN+0YXeUO9nVGh#AH0ti>4P1l4{;Dw9ONJdkb@W)Z6PXk6vBYs&CJiU zHPkZzK^+C>(wxaXY_hz0r9j0XrR+dr^3Jcyh9DjYFxEq8h*1oT96;^{`}lgnt6WxK zc`(7qC^b3IR%-GM8$n&Ddg63W=GRgtO~>>O2S!yAwS4Gh6qzm~z$iF98Ay<(d9w8{ zZPG&nl-9&12Qae~F!I0x1dS#xWWmA9Rb~Q=FJl8^LrX?RZaqKO5a;}&RL6n>aD0K3 J{D%TY1_0Rcn3Vtk delta 31 ncmcb4o~``^8wVTXZUzPh#@NY%LY~t<