Because terminals will send escape-sequences starting with escape,
ncurses will pause after receiving a signle escape, to detect
these sequences. This introduces a 1-second delay when exiting the
petitboot UI.
Instead, use 'x'.
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
"Petitboot (" PACKAGE_VERSION ")");
m->scr.frame.rtitle = NULL;
m->scr.frame.help = talloc_strdup(m,
"Petitboot (" PACKAGE_VERSION ")");
m->scr.frame.rtitle = NULL;
m->scr.frame.help = talloc_strdup(m,
- "ESC=exit, Enter=accept, e=edit, n=new");
+ "Enter=accept, e=edit, n=new, x=exit");
m->scr.frame.status = talloc_strdup(m, "Welcome to Petitboot");
i = pmenu_item_init(m, 0, "Exit to Shell");
m->scr.frame.status = talloc_strdup(m, "Welcome to Petitboot");
i = pmenu_item_init(m, 0, "Exit to Shell");
- * cui_on_exit - A generic main menu ESC callback.
+ * cui_on_exit - A generic main menu exit callback.
*/
void cui_on_exit(struct pmenu *menu)
*/
void cui_on_exit(struct pmenu *menu)
switch (key) {
case 27: /* ESC */
switch (key) {
case 27: /* ESC */
if (menu->on_exit)
menu->on_exit(menu);
nc_flush_keys();
if (menu->on_exit)
menu->on_exit(menu);
nc_flush_keys();
- * ps3_svm_to_mm_helper - The svm ESC callback.
+ * ps3_svm_to_mm_helper - The svm exit callback.
*/
static void ps3_svm_to_mm_helper(struct pmenu *menu)
*/
static void ps3_svm_to_mm_helper(struct pmenu *menu)
m->scr.frame.title = talloc_strdup(m, "Petitboot PS3");
#endif
m->scr.frame.help = talloc_strdup(m,
m->scr.frame.title = talloc_strdup(m, "Petitboot PS3");
#endif
m->scr.frame.help = talloc_strdup(m,
- "ESC=exit, Enter=accept, e=edit, o=open");
+ "Enter=accept, e=edit, o=open, x=exit");
m->scr.frame.status = talloc_strdup(m, "Welcome to Petitboot");
i = pmenu_item_init(m, 0, "Boot GameOS");
m->scr.frame.status = talloc_strdup(m, "Welcome to Petitboot");
i = pmenu_item_init(m, 0, "Boot GameOS");
m->hot_key = ps3_hot_key;
m->scr.frame.title = talloc_strdup(m, "Select PS3 Video Mode");
m->hot_key = ps3_hot_key;
m->scr.frame.title = talloc_strdup(m, "Select PS3 Video Mode");
- m->scr.frame.help = talloc_strdup(m, "ESC=exit, Enter=accept");
+ m->scr.frame.help = talloc_strdup(m, "Enter=accept, x=exit");
i = pmenu_item_init(m, 0, "auto detect");
i->on_execute = ps3_svm_cb;
i = pmenu_item_init(m, 0, "auto detect");
i->on_execute = ps3_svm_cb;