Cursive::default fallbacks to dummy backend if nothing else is available

This commit is contained in:
Alexandre Bury 2019-10-09 15:38:51 -07:00
parent c34aeab99a
commit 6a29371076

View File

@ -93,6 +93,13 @@ cfg_if::cfg_if! {
Self::ncurses().unwrap() Self::ncurses().unwrap()
} }
} }
} else {
impl Default for Cursive {
fn default() -> Self {
log::warning!("No built-it backend, falling back to Cursive::dummy().");
Self::dummy()
}
}
} }
} }