Helper class, don't construct this directly. More...
#include <wml_exception.hpp>
Public Member Functions | |
twml_exception (const std::string &user_msg, const std::string &dev_msg) | |
~twml_exception () throw () | |
void | show (CVideo &video) |
Shows the error in a dialog. More... | |
Public Member Functions inherited from tlua_jailbreak_exception | |
virtual | ~tlua_jailbreak_exception () throw () |
void | store () const throw () |
Stores a copy the current exception to be rethrown. More... | |
Public Attributes | |
std::string | user_message |
The message for the user explaining what went wrong. More... | |
std::string | dev_message |
The message for developers telling which problem was triggered, this shouldn't be translated. More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from tlua_jailbreak_exception | |
static void | rethrow () |
Rethrows the stored exception. More... | |
Static Protected Attributes inherited from tlua_jailbreak_exception | |
static tlua_jailbreak_exception * | jailbreak_exception = nullptr |
The exception to be rethrown. More... | |
Helper class, don't construct this directly.
Definition at line 107 of file wml_exception.hpp.
|
inline |
Definition at line 110 of file wml_exception.hpp.
|
inline |
Definition at line 116 of file wml_exception.hpp.
Shows the error in a dialog.
video | Target for rendering the UI message. |
Definition at line 57 of file wml_exception.cpp.
References _(), dev_message, gui2::show_error_message(), and user_message.
Referenced by ad_hoc_addon_fetch_session(), editor::editor_controller::do_screenshot(), sp::enter_create_mode(), game_launcher::launch_game(), game_launcher::load_game(), editor::editor_controller::main_loop(), campaign_controller::play_game(), game_launcher::play_multiplayer(), game_launcher::play_replay(), and game_events::WML_HANDLER_FUNCTION().
std::string twml_exception::dev_message |
The message for developers telling which problem was triggered, this shouldn't be translated.
It's hard for a dev to parse errors in foreign tongues.
Definition at line 129 of file wml_exception.hpp.
Referenced by game_info::game_info(), main(), mp::gamebrowser::populate_game_item_map_info(), ng::scenario::set_metadata(), show(), and game_launcher::unit_test().
std::string twml_exception::user_message |
The message for the user explaining what went wrong.
This message can be translated so the user gets a explanation in his/her native tongue.
Definition at line 122 of file wml_exception.hpp.
Referenced by BOOST_AUTO_TEST_CASE(), editor::editor_map::from_string(), main(), and show().