Add drop event.

This commit is contained in:
qianlifeng
2015-02-03 18:32:16 +08:00
parent 38948053cc
commit 5d9a94466a
8 changed files with 30 additions and 25 deletions

View File

@@ -19,6 +19,7 @@ using Wox.Core.UI;
using Wox.Core.Updater;
using Wox.Core.UserSettings;
using Wox.Infrastructure.Http;
using Wox.Infrastructure.Logger;
namespace Wox.CrashReporter
{
@@ -53,15 +54,12 @@ namespace Wox.CrashReporter
private void SendReport()
{
Hide();
string error = string.Format("{{\"data\":{0}}}", ExceptionFormatter.FormatExcpetion(exception));
string response = HttpRequest.Post(APIServer.ErrorReportURL, error, HttpProxy.Instance);
if (response.ToLower() == "ok")
if (response.ToLower() != "ok")
{
MessageBox.Show(InternationalizationManager.Instance.GetTranslation("reportWindow_report_succeed"));
}
else
{
MessageBox.Show(InternationalizationManager.Instance.GetTranslation("reportWindow_report_failed"));
Log.Warn("sending crash report failed: " + response);
}
Dispatcher.Invoke(new Action(Close));
}