refactored MainWindow and Engine, changed project structure
This commit is contained in:
27
src/gui/gui_exceptions.hpp
Normal file
27
src/gui/gui_exceptions.hpp
Normal file
@@ -0,0 +1,27 @@
|
||||
#pragma once
|
||||
|
||||
|
||||
#include "../common/std.hpp"
|
||||
#include "../common/UsefulException.hpp"
|
||||
|
||||
namespace ougge::gui {
|
||||
|
||||
#define SDLException() SDLException_(__FILE__, __func__, __LINE__)
|
||||
|
||||
class SDLException_ : public UsefulException_ {
|
||||
public:
|
||||
SDLException_(const std::string& _file, const std::string& _func, int line_n);
|
||||
};
|
||||
|
||||
|
||||
#define IMGException() IMGException_(__FILE__, __func__, __LINE__)
|
||||
|
||||
class IMGException_ : public UsefulException_ {
|
||||
public:
|
||||
IMGException_(const std::string& _file, const std::string& _func, int line_n);
|
||||
};
|
||||
|
||||
|
||||
#define SDL_TRY(EXPR) if(EXPR) throw ::ougge::gui::SDLException();
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user