From 59255c556db6a1fbb94458d87f798a58d39a056f Mon Sep 17 00:00:00 2001 From: Guillaume Cottenceau Date: Wed, 24 Jul 2002 14:05:11 +0000 Subject: enhance (complicate? ;p) device detection so that scsi and usb detection are done only when no ide cdrom with mandrake install is detected (speed up), have usb keyboard modules installed before any interactive question, honour "noauto" (skip usb detection and insmod'ing) --- mdk-stage1/newt-frontend.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'mdk-stage1/newt-frontend.c') diff --git a/mdk-stage1/newt-frontend.c b/mdk-stage1/newt-frontend.c index f50defee1..9d14dfc84 100644 --- a/mdk-stage1/newt-frontend.c +++ b/mdk-stage1/newt-frontend.c @@ -33,6 +33,8 @@ #include #include "newt/newt.h" +#include + #include "frontend.h" void init_frontend(char * welcome_msg) @@ -175,6 +177,8 @@ enum return_type ask_from_list_comments(char *msg, char ** elems, char ** elems_ char ** sav_elems = elems; int i; + probe_that_type(USB_CONTROLLERS, BUS_USB); // we'd need the keyboard for interactions so... + i = 0; while (elems && *elems) { int j = (*elems_comments) ? strlen(*elems_comments) : 0; @@ -206,6 +210,8 @@ enum return_type ask_from_list(char *msg, char ** elems, char ** choice) { int answer = 0, rc; + probe_that_type(USB_CONTROLLERS, BUS_USB); // we'd need the keyboard for interactions so... + rc = newtWinMenu("Please choose...", msg, 52, 5, 5, 7, elems, &answer, "Ok", "Cancel", NULL); if (rc == 2) @@ -221,6 +227,8 @@ enum return_type ask_yes_no(char *msg) { int rc; + probe_that_type(USB_CONTROLLERS, BUS_USB); // we'd need the keyboard for interactions so... + rc = newtWinTernary("Please answer...", "Yes", "No", "Back", msg); if (rc == 1) @@ -358,6 +366,8 @@ enum return_type ask_from_entries(char *msg, char ** questions, char *** answers int rc; char ** already_answers = NULL; + probe_that_type(USB_CONTROLLERS, BUS_USB); // we'd need the keyboard for interactions so... + while (questions && *questions) { entries[i].text = *questions; entries[i].flags = NEWT_FLAG_SCROLL | (!strcmp(*questions, "Password") ? NEWT_FLAG_PASSWORD : 0); -- cgit v1.2.1