]> git.tdb.fi Git - libs/gui.git/blobdiff - source/graphics/errordialog.h
Implement graphical reporting for uncaught exceptions
[libs/gui.git] / source / graphics / errordialog.h
diff --git a/source/graphics/errordialog.h b/source/graphics/errordialog.h
new file mode 100644 (file)
index 0000000..7ece72e
--- /dev/null
@@ -0,0 +1,25 @@
+#ifndef MSP_GRAPHICS_ERRORDIALOG_H_
+#define MSP_GRAPHICS_ERRORDIALOG_H_
+
+#include <msp/debug/errorreporter.h>
+
+namespace Msp {
+namespace Graphics {
+
+class Display;
+
+class ErrorDialog: public Debug::ErrorReporter
+{
+private:
+       Display *display;
+
+public:
+       ErrorDialog(Display *d): display(d) { }
+
+       virtual bool report_uncaught_exception(const std::exception &) const;
+};
+
+} // namespace Graphics
+} // namespace Msp
+
+#endif