From 744ee4095f32733669e2234c11a77d1f7524a97d Mon Sep 17 00:00:00 2001 From: "Samir L. Boulema" Date: Mon, 22 Aug 2016 09:21:36 +0200 Subject: [PATCH] #21 --- TGit/OutputBox.cs | 14 ++++++++------ TGit/source.extension.vsixmanifest | 2 +- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/TGit/OutputBox.cs b/TGit/OutputBox.cs index dca15a9..14f8e09 100644 --- a/TGit/OutputBox.cs +++ b/TGit/OutputBox.cs @@ -55,12 +55,7 @@ private void okButton_Click(object sender, EventArgs e) string.Empty, this ); process.WaitForExit(); - if (process.ExitCode == 0) - { - Close(); - richTextBox.Clear(); - okButton.Enabled = false; - } + okButton.Click += OkButton_Click_Close; } else { @@ -70,6 +65,13 @@ private void okButton_Click(object sender, EventArgs e) } } + private void OkButton_Click_Close(object sender, EventArgs e) + { + Close(); + richTextBox.Clear(); + okButton.Enabled = false; + } + private static string FormatCliCommand(string gitCommand, bool appendNextLine = true) { return $"echo ^> {Path.GetFileNameWithoutExtension(FileHelper.GetMSysGit())} {gitCommand} && \"{FileHelper.GetMSysGit()}\" {gitCommand}{(appendNextLine ? " && " : string.Empty)}"; diff --git a/TGit/source.extension.vsixmanifest b/TGit/source.extension.vsixmanifest index be91585..adef7cb 100644 --- a/TGit/source.extension.vsixmanifest +++ b/TGit/source.extension.vsixmanifest @@ -1,7 +1,7 @@  - + TGit Control TortoiseGit from within Visual Studio https://github.com/sboulema/TGit