]> git.ozlabs.org Git - petitboot/blobdiff - ui/ncurses/ps3-main.c
ui/ncurses: Use 'x' as exit key
[petitboot] / ui / ncurses / ps3-main.c
index 57350556dc9489539c72490300a1a853ab269840..c4a3892887b3f212130b9a630c5aa91b329d451d 100644 (file)
  * ncurses mouse support
  */
 
-#if defined(HAVE_CONFIG_H)
 #include "config.h"
-#endif
 
 #define _GNU_SOURCE
+
+#include <assert.h>
 #include <errno.h>
 #include <getopt.h>
 #include <signal.h>
@@ -343,7 +343,7 @@ static int ps3_svm_to_mm_cb(struct pmenu_item *item)
 }
 
 /**
- * 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)
@@ -412,7 +412,7 @@ static struct pmenu *ps3_mm_init(struct ps3_cui *ps3_cui)
        }
 
        m->hot_key = ps3_hot_key;
-       m->on_open = cui_on_open;
+       m->on_new = cui_item_new;
 
 #if defined(DEBUG)
        m->scr.frame.title = talloc_strdup(m,
@@ -421,7 +421,7 @@ static struct pmenu *ps3_mm_init(struct ps3_cui *ps3_cui)
        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");
@@ -472,7 +472,7 @@ static struct pmenu *ps3_svm_init(struct ps3_cui *ps3_cui)
 
        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;