editor: Print error to stderr if display::screenshot() fails
This is used by the --screenshot command line option.
This commit is contained in:
parent
6a2abfcb78
commit
5de0bbbf28
1 changed files with 3 additions and 1 deletions
|
@ -191,7 +191,9 @@ void editor_controller::status_table() {
|
|||
void editor_controller::do_screenshot(const std::string& screenshot_filename /* = "map_screenshot.bmp" */)
|
||||
{
|
||||
try {
|
||||
gui().screenshot(screenshot_filename,true);
|
||||
if (!gui().screenshot(screenshot_filename,true)) {
|
||||
ERR_ED << "Screenshot creation failed!\n";
|
||||
}
|
||||
} catch (twml_exception& e) {
|
||||
e.show(gui());
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue