From ce941c146aea7925bded6b9d2a0d0559d3156ad3 Mon Sep 17 00:00:00 2001 From: Loic Guegan Date: Wed, 23 Feb 2022 18:11:55 +0100 Subject: Create repository --- src/ochess.cpp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/ochess.cpp (limited to 'src/ochess.cpp') diff --git a/src/ochess.cpp b/src/ochess.cpp new file mode 100644 index 0000000..3510568 --- /dev/null +++ b/src/ochess.cpp @@ -0,0 +1,18 @@ +#include "ochess.hpp" +#include "MainWindow.hpp" + +bool MyApp::OnInit() { + wxImage::AddHandler(new wxPNGHandler); + + MainWindow *frame = new MainWindow(); + frame->Show(true); + return true; +} +wxIMPLEMENT_APP(MyApp); + +void Abort(std::string msg) { + wxMessageDialog *dial = new wxMessageDialog(NULL, wxString(msg), wxT("Error"), + wxOK | wxICON_ERROR); + dial->ShowModal(); + wxLogFatalError(wxString(msg)); +} -- cgit v1.2.3