]> git.lyx.org Git - features.git/commitdiff
Gives the user some information about the crash.
authorAbdelrazak Younes <younes@lyx.org>
Thu, 27 Sep 2007 09:49:14 +0000 (09:49 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Thu, 27 Sep 2007 09:49:14 +0000 (09:49 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20531 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/GuiApplication.cpp

index b9d43faf04bd6699650b072decfbda0809de9de6..1427e0c4992f2078ad250ce7a4d5d2b889051b96 100644 (file)
@@ -296,12 +296,18 @@ bool GuiApplication::notify(QObject * receiver, QEvent * event)
                }
        }
        catch (std::exception  const & e) {
-               lyxerr << "Caught \"normal\" exception: " << e.what() << endl;
+               docstring s = _("LyX has caught an exception, it will now "
+                       "attemp to save all unsaved documents and exit."
+                       "\n\nException: ");
+               s += from_ascii(e.what());
+               Alert::error(_("Software exception Detected"), s);
                LyX::cref().emergencyCleanup();
                QApplication::exit(1);
        }
        catch (...) {
-               lyxerr << "Caught some really weird exception..." << endl;
+               docstring s = _("LyX has caught some really weird exception, it will "
+                       "now attemp to save all unsaved documents and exit.");
+               Alert::error(_("Software exception Detected"), s);
                LyX::cref().emergencyCleanup();
                QApplication::exit(1);
        }