mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-11-11 11:13:01 +00:00
text improvements, PL/CZ translation update
This commit is contained in:
14
dialogs.cpp
14
dialogs.cpp
@@ -1058,6 +1058,20 @@ namespace dialog {
|
||||
numberdark = 0;
|
||||
}
|
||||
|
||||
void confirm_dialog(const string& text, const reaction_t& act) {
|
||||
gamescreen(1);
|
||||
dialog::addBreak(250);
|
||||
dialog::init(XLAT("WARNING"), 0xFF0000, 150, 100);
|
||||
dialog::addInfo(text);
|
||||
dialog::addItem(XLAT("YES"), 'y');
|
||||
auto yes = [act] () { popScreen(); act(); };
|
||||
dialog::add_action(yes);
|
||||
dialog::add_key_action(SDLK_RETURN, yes);
|
||||
dialog::addItem(XLAT("NO"), 'n');
|
||||
dialog::add_action([] () { popScreen(); });
|
||||
dialog::display();
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user