Buttons are now decoded with quotes surrounding them.

This commit is contained in:
Filipe Rodrigues 2021-05-19 15:27:25 +01:00
parent 3fe6b0ee0c
commit c0d7ef0667

View File

@ -166,7 +166,14 @@ impl State {
(State::Menu { menu, buttons }, Command::FinishMenu) => {
println!(
"menu {menu:?}, {}",
buttons.iter().map(|button| button.as_str()).format(", ")
buttons
.iter()
.map(|button| dcb_util::DisplayWrapper::new(move |f| write!(
f,
"\"{}\"",
button.as_str().escape_debug()
)))
.format(", ")
);
*self = State::Start;