Skip to content

Commit

Permalink
[Feature] Add 'Cancel' to quit (Bugsplat dialog) (#360), version 1.2.8.3
Browse files Browse the repository at this point in the history
  • Loading branch information
Hofknecht committed Feb 19, 2022
1 parent e6bd977 commit 7256910
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
14 changes: 9 additions & 5 deletions Business/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,20 +55,24 @@ static void AskUserSendError(Exception ex)
{
Log.Error("Application Crashed", ex);

if (MessageBox.Show(
DialogResult dialogResult = MessageBox.Show(
"A problem has been encountered and the application needs to restart. " +
"Reporting this error will help us make our product better. " +
"Press yes to open your standard email app.",
"SystemTrayMenu BugSplat",
MessageBoxButtons.YesNo) == DialogResult.Yes)
"Press 'Yes' to open your standard email app (emailto: [email protected]). " + Environment.NewLine +
@"You can also create a issue manually here https://github.com/Hofknecht/SystemTrayMenu/issues" + Environment.NewLine +
"Press 'Cancel' to quit SystemTrayMenu.",
"SystemTrayMenu Crashed",
MessageBoxButtons.YesNoCancel);

if (dialogResult == DialogResult.Yes)
{
Log.ProcessStart("mailto:" + "[email protected]" +
"?subject=SystemTrayMenu Bug reported " +
Assembly.GetEntryAssembly().GetName().Version +
"&body=" + ex.ToString());
}

if (!isStartup)
if (!isStartup && dialogResult != DialogResult.Cancel)
{
AppRestart.ByThreadException();
}
Expand Down
4 changes: 2 additions & 2 deletions Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.2.8.1")]
[assembly: AssemblyFileVersion("1.2.8.1")]
[assembly: AssemblyVersion("1.2.8.3")]
[assembly: AssemblyFileVersion("1.2.8.3")]

0 comments on commit 7256910

Please sign in to comment.