From 01df6ba1692b6f7b75423a978e41014e2d9cc218 Mon Sep 17 00:00:00 2001 From: Amar Takhar Date: Wed, 2 Sep 2009 20:46:15 +0000 Subject: [PATCH] Remove the dual exception messages and strip it down to 1 short one, removing all references to crashlog.txt. Originally committed to SVN as r3471. --- aegisub/src/main.cpp | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/aegisub/src/main.cpp b/aegisub/src/main.cpp index 5608f4beb..1e67c4185 100644 --- a/aegisub/src/main.cpp +++ b/aegisub/src/main.cpp @@ -279,12 +279,8 @@ int AegisubApp::OnExit() { #if !defined(_DEBUG) || defined(WITH_EXCEPTIONS) -/// DOCME -const static wxChar unhandled_exception_message[] = _T("Oops, Aegisub has crashed!\n\nI have tried to emergency-save a copy of your file, and a crash log file has been generated.\n\nYou can find the emergency-saved file in:\n%s\n\nIf you submit the crash log to the Aegisub team, we will investigate the problem and attempt to fix it. You can find the crashlog in:\n%s\n\nAegisub will now close."); - -/// DOCME -const static wxChar unhandled_exception_message_nocrashlog[] = _T("Oops, Aegisub has crashed!\n\nI have tried to emergency-save a copy of your file.\n\nYou can find the emergency-saved file in:\n%s\n\nAegisub will now close."); - +/// Message displayed when an exception has occurred. +const static wxString exception_message = _("Oops, Aegisub has crashed!\n\nAn attempt has been made to save a copy of your file to:\n\n%s\n\nAegisub will now close."); /// @brief Unhandled exception /// @@ -302,7 +298,7 @@ void AegisubApp::OnUnhandledException() { AssFile::top->Save(filename,false,false); // Inform user of crash - wxMessageBox(wxString::Format(unhandled_exception_message, filename.c_str(), StandardPaths::DecodePath(_T("?user/crashlog.txt")).c_str()), _T("Unhandled exception"), wxOK | wxICON_ERROR, NULL); + wxMessageBox(wxString::Format(exception_message, filename.c_str()), _("Program error"), wxOK | wxICON_ERROR, NULL); } @@ -326,13 +322,9 @@ void AegisubApp::OnFatalException() { // Stack walk StackWalker walker(_T("Fatal exception")); walker.WalkFromException(); - - // Inform user of crash - wxMessageBox(wxString::Format(unhandled_exception_message, filename.c_str(), StandardPaths::DecodePath(_T("?user/crashlog.txt")).c_str()), _T("Fatal exception"), wxOK | wxICON_ERROR, NULL); -#else - // Inform user of crash - wxMessageBox(wxString::Format(unhandled_exception_message_nocrashlog, filename.c_str()), _T("Fatal exception"), wxOK | wxICON_ERROR, NULL); #endif + // Inform user of crash + wxMessageBox(wxString::Format(exception_message, filename.c_str()), _("Program error"), wxOK | wxICON_ERROR, NULL); } #endif