Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/monodevelop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan McGovern <alan.mcgovern@gmail.com>2012-01-05 14:51:55 +0400
committerAlan McGovern <alan.mcgovern@gmail.com>2012-01-05 15:04:48 +0400
commit319199a15b0831ad59c8be5a1dd43689d8e7e054 (patch)
treef34df478791341f74b213a1bef4383ec2c32f1ac
parent609b641195e23ca9b18aa6a0a94596d73e836e54 (diff)
[Core] Add an env var to allow easy testing of crash reporting
If the 'MONODEVELOP_FEEDBACK_THROWS_EXCEPTION' env var has a non-null value, then clicking on the feedback button in the bottom right of MonoDevelop will create an exception which will be processed as a normal unhandled exception.
-rw-r--r--main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs6
1 files changed, 6 insertions, 0 deletions
diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs
index ab1b615326..8f693d5e47 100644
--- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs
+++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs
@@ -203,8 +203,14 @@ namespace MonoDevelop.Ide
ignoreFeedbackButtonClick = true;
}
+ static readonly bool FeedbackButtonThrowsException = Environment.GetEnvironmentVariable ("MONODEVELOP_FEEDBACK_THROWS_EXCEPTION") != null;
void HandleFeedbackButtonClicked (object sender, EventArgs e)
{
+ if (FeedbackButtonThrowsException) {
+ GLib.ExceptionManager.RaiseUnhandledException (new Exception ("Feedback Button is throwing an exception", new Exception (Environment.StackTrace)), false);
+ return;
+ }
+
if (!ignoreFeedbackButtonClick)
FeedbackService.ShowFeedbackWindow ();
ignoreFeedbackButtonClick = false;