Reformatting, more sanity checks.
This commit is contained in:
parent
9f5f4b12f4
commit
09b58bbc77
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: menus.c,v 1.159 1998/03/10 13:42:04 jkh Exp $
|
* $Id: menus.c,v 1.160 1998/03/13 11:30:44 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -341,35 +341,25 @@ DMenu MenuMouseType = {
|
|||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
{ { "Auto", "Bus mouse, PS/2 style mouse or PnP serial mouse",
|
{ { "Auto", "Bus mouse, PS/2 style mouse or PnP serial mouse",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=auto" },
|
||||||
VAR_MOUSED_TYPE "=auto" },
|
|
||||||
{ "GlidePoint", "ALPS GlidePoint pad (serial)",
|
{ "GlidePoint", "ALPS GlidePoint pad (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=glidepoint" },
|
||||||
VAR_MOUSED_TYPE "=glidepoint" },
|
|
||||||
{ "Hitachi","Hitachi tablet (serial)",
|
{ "Hitachi","Hitachi tablet (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mmhittab" },
|
||||||
VAR_MOUSED_TYPE "=mmhittab" },
|
|
||||||
{ "IntelliMouse", "Microsoft IntelliMouse (serial)",
|
{ "IntelliMouse", "Microsoft IntelliMouse (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=intellimouse" },
|
||||||
VAR_MOUSED_TYPE "=intellimouse" },
|
|
||||||
{ "Logitech", "Logitech protocol (old models) (serial)",
|
{ "Logitech", "Logitech protocol (old models) (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=logitech" },
|
||||||
VAR_MOUSED_TYPE "=logitech" },
|
|
||||||
{ "Microsoft", "Microsoft protocol (serial)",
|
{ "Microsoft", "Microsoft protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=microsoft" },
|
||||||
VAR_MOUSED_TYPE "=microsoft" },
|
|
||||||
{ "MM Series","MM Series protocol (serial)",
|
{ "MM Series","MM Series protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mmseries" },
|
||||||
VAR_MOUSED_TYPE "=mmseries" },
|
|
||||||
{ "MouseMan", "Logitech MouseMan/TrackMan models (serial)",
|
{ "MouseMan", "Logitech MouseMan/TrackMan models (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mouseman" },
|
||||||
VAR_MOUSED_TYPE "=mouseman" },
|
|
||||||
{ "MouseSystems", "MouseSystems protocol (serial)",
|
{ "MouseSystems", "MouseSystems protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mousesystems" },
|
||||||
VAR_MOUSED_TYPE "=mousesystems" },
|
|
||||||
{ "ThinkingMouse","Kensington ThinkingMouse (serial)",
|
{ "ThinkingMouse","Kensington ThinkingMouse (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=thinkingmouse" },
|
||||||
VAR_MOUSED_TYPE "=thinkingmouse" },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -381,23 +371,17 @@ DMenu MenuMousePort = {
|
|||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
{ { "COM1", "Serial mouse on COM1 (/dev/cuaa0)",
|
{ { "COM1", "Serial mouse on COM1 (/dev/cuaa0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa0" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa0" },
|
|
||||||
{ "COM2", "Serial mouse on COM2 (/dev/cuaa1)",
|
{ "COM2", "Serial mouse on COM2 (/dev/cuaa1)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa1" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa1" },
|
|
||||||
{ "COM3", "Serial mouse on COM3 (/dev/cuaa2)",
|
{ "COM3", "Serial mouse on COM3 (/dev/cuaa2)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa2" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa2" },
|
|
||||||
{ "COM4", "Serial mouse on COM4 (/dev/cuaa3)",
|
{ "COM4", "Serial mouse on COM4 (/dev/cuaa3)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa3" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa3" },
|
|
||||||
{ "BusMouse", "Logitech, ATI or MS bus mouse (/dev/mse0)",
|
{ "BusMouse", "Logitech, ATI or MS bus mouse (/dev/mse0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/mse0" },
|
||||||
VAR_MOUSED_PORT "=/dev/mse0" },
|
|
||||||
{ "PS/2", "PS/2 style mouse (must enable /dev/psm0)",
|
{ "PS/2", "PS/2 style mouse (must enable /dev/psm0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/psm0" },
|
||||||
VAR_MOUSED_PORT "=/dev/psm0" },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -412,17 +396,12 @@ DMenu MenuMouse = {
|
|||||||
"Configuration menu).",
|
"Configuration menu).",
|
||||||
"Choose 3 after selecting a protocol and a port.",
|
"Choose 3 after selecting a protocol and a port.",
|
||||||
NULL,
|
NULL,
|
||||||
{ { "1 Type", "Select mouse protocol",
|
{ { "1 Type", "Select mouse protocol", NULL, dmenuSubmenu, NULL, &MenuMouseType },
|
||||||
NULL, dmenuSubmenu, NULL, &MenuMouseType },
|
{ "2 Port", "Select mouse port", NULL, dmenuSubmenu, NULL, &MenuMousePort },
|
||||||
{ "2 Port", "Select mouse port",
|
{ "3 Daemon", "Test and run the mouse daemon", NULL, mousedTest, NULL, NULL },
|
||||||
NULL, dmenuSubmenu, NULL, &MenuMousePort },
|
{ "4 No mouse", "Clear mouse configuration", NULL, dmenuSetVariables,
|
||||||
{ "3 Daemon", "Test and run the mouse daemon",
|
NULL, VAR_MOUSED "=NO, " VAR_MOUSED_TYPE "=NO, " VAR_MOUSED_PORT "=" },
|
||||||
NULL, mousedTest, NULL, NULL },
|
{ "0 Exit", "Exit this menu (returning to previous)", NULL, dmenuExit },
|
||||||
{ "4 No mouse", "Clear mouse configuration",
|
|
||||||
NULL, dmenuSetVariables, NULL,
|
|
||||||
VAR_MOUSED "=NO, " VAR_MOUSED_TYPE "=NO, " VAR_MOUSED_PORT "=" },
|
|
||||||
{ "0 Exit", "Exit this menu (returning to previous)",
|
|
||||||
NULL, dmenuExit },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -1248,11 +1227,10 @@ DMenu MenuNTP = {
|
|||||||
"These are the primary open-access NTP servers",
|
"These are the primary open-access NTP servers",
|
||||||
NULL,
|
NULL,
|
||||||
{ { "None", "No ntp server",
|
{ { "None", "No ntp server",
|
||||||
dmenuVarCheck, dmenuSetVariables, NULL,
|
dmenuVarsCheck, dmenuSetVariables, NULL,
|
||||||
"ntpdate_enable=NO,ntpdate_flags=" },
|
"ntpdate_enable=NO,ntpdate_flags=none" },
|
||||||
{ "Other", "Select a site not on this list",
|
{ "Other", "Select a site not on this list",
|
||||||
dmenuVarsCheck, configNTP, NULL,
|
dmenuVarsCheck, configNTP, NULL, NULL },
|
||||||
NULL },
|
|
||||||
{ "Australia", "ntp.syd.dms.csiro.au (HP 5061 Cesium Beam)",
|
{ "Australia", "ntp.syd.dms.csiro.au (HP 5061 Cesium Beam)",
|
||||||
dmenuVarsCheck, dmenuSetVariables, NULL,
|
dmenuVarsCheck, dmenuSetVariables, NULL,
|
||||||
"ntpdate_enable=YES,ntpdate_flags=ntp.syd.dms.csiro.au" },
|
"ntpdate_enable=YES,ntpdate_flags=ntp.syd.dms.csiro.au" },
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: variable.c,v 1.21 1997/10/12 16:21:21 jkh Exp $
|
* $Id: variable.c,v 1.22 1998/03/10 17:24:08 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -183,15 +183,18 @@ variable_check(char *data)
|
|||||||
if ((cp3 = index(cp, '"')) != NULL)
|
if ((cp3 = index(cp, '"')) != NULL)
|
||||||
*cp3 = '\0';
|
*cp3 = '\0';
|
||||||
}
|
}
|
||||||
if ((cp3 = index(cp, ',')) != NULL)
|
else if ((cp3 = index(cp, ',')) != NULL)
|
||||||
*cp3 = '\0';
|
*cp3 = '\0';
|
||||||
cp2 = getenv(tmp);
|
cp2 = getenv(tmp);
|
||||||
|
if (cp2) {
|
||||||
if (cp2)
|
if (!*cp)
|
||||||
|
return TRUE;
|
||||||
|
else
|
||||||
return !strcmp(cp, cp2);
|
return !strcmp(cp, cp2);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
return getenv(tmp) ? 1 : 0;
|
return getenv(tmp) ? TRUE : FALSE;
|
||||||
}
|
}
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: menus.c,v 1.159 1998/03/10 13:42:04 jkh Exp $
|
* $Id: menus.c,v 1.160 1998/03/13 11:30:44 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -341,35 +341,25 @@ DMenu MenuMouseType = {
|
|||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
{ { "Auto", "Bus mouse, PS/2 style mouse or PnP serial mouse",
|
{ { "Auto", "Bus mouse, PS/2 style mouse or PnP serial mouse",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=auto" },
|
||||||
VAR_MOUSED_TYPE "=auto" },
|
|
||||||
{ "GlidePoint", "ALPS GlidePoint pad (serial)",
|
{ "GlidePoint", "ALPS GlidePoint pad (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=glidepoint" },
|
||||||
VAR_MOUSED_TYPE "=glidepoint" },
|
|
||||||
{ "Hitachi","Hitachi tablet (serial)",
|
{ "Hitachi","Hitachi tablet (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mmhittab" },
|
||||||
VAR_MOUSED_TYPE "=mmhittab" },
|
|
||||||
{ "IntelliMouse", "Microsoft IntelliMouse (serial)",
|
{ "IntelliMouse", "Microsoft IntelliMouse (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=intellimouse" },
|
||||||
VAR_MOUSED_TYPE "=intellimouse" },
|
|
||||||
{ "Logitech", "Logitech protocol (old models) (serial)",
|
{ "Logitech", "Logitech protocol (old models) (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=logitech" },
|
||||||
VAR_MOUSED_TYPE "=logitech" },
|
|
||||||
{ "Microsoft", "Microsoft protocol (serial)",
|
{ "Microsoft", "Microsoft protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=microsoft" },
|
||||||
VAR_MOUSED_TYPE "=microsoft" },
|
|
||||||
{ "MM Series","MM Series protocol (serial)",
|
{ "MM Series","MM Series protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mmseries" },
|
||||||
VAR_MOUSED_TYPE "=mmseries" },
|
|
||||||
{ "MouseMan", "Logitech MouseMan/TrackMan models (serial)",
|
{ "MouseMan", "Logitech MouseMan/TrackMan models (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mouseman" },
|
||||||
VAR_MOUSED_TYPE "=mouseman" },
|
|
||||||
{ "MouseSystems", "MouseSystems protocol (serial)",
|
{ "MouseSystems", "MouseSystems protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mousesystems" },
|
||||||
VAR_MOUSED_TYPE "=mousesystems" },
|
|
||||||
{ "ThinkingMouse","Kensington ThinkingMouse (serial)",
|
{ "ThinkingMouse","Kensington ThinkingMouse (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=thinkingmouse" },
|
||||||
VAR_MOUSED_TYPE "=thinkingmouse" },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -381,23 +371,17 @@ DMenu MenuMousePort = {
|
|||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
{ { "COM1", "Serial mouse on COM1 (/dev/cuaa0)",
|
{ { "COM1", "Serial mouse on COM1 (/dev/cuaa0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa0" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa0" },
|
|
||||||
{ "COM2", "Serial mouse on COM2 (/dev/cuaa1)",
|
{ "COM2", "Serial mouse on COM2 (/dev/cuaa1)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa1" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa1" },
|
|
||||||
{ "COM3", "Serial mouse on COM3 (/dev/cuaa2)",
|
{ "COM3", "Serial mouse on COM3 (/dev/cuaa2)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa2" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa2" },
|
|
||||||
{ "COM4", "Serial mouse on COM4 (/dev/cuaa3)",
|
{ "COM4", "Serial mouse on COM4 (/dev/cuaa3)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa3" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa3" },
|
|
||||||
{ "BusMouse", "Logitech, ATI or MS bus mouse (/dev/mse0)",
|
{ "BusMouse", "Logitech, ATI or MS bus mouse (/dev/mse0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/mse0" },
|
||||||
VAR_MOUSED_PORT "=/dev/mse0" },
|
|
||||||
{ "PS/2", "PS/2 style mouse (must enable /dev/psm0)",
|
{ "PS/2", "PS/2 style mouse (must enable /dev/psm0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/psm0" },
|
||||||
VAR_MOUSED_PORT "=/dev/psm0" },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -412,17 +396,12 @@ DMenu MenuMouse = {
|
|||||||
"Configuration menu).",
|
"Configuration menu).",
|
||||||
"Choose 3 after selecting a protocol and a port.",
|
"Choose 3 after selecting a protocol and a port.",
|
||||||
NULL,
|
NULL,
|
||||||
{ { "1 Type", "Select mouse protocol",
|
{ { "1 Type", "Select mouse protocol", NULL, dmenuSubmenu, NULL, &MenuMouseType },
|
||||||
NULL, dmenuSubmenu, NULL, &MenuMouseType },
|
{ "2 Port", "Select mouse port", NULL, dmenuSubmenu, NULL, &MenuMousePort },
|
||||||
{ "2 Port", "Select mouse port",
|
{ "3 Daemon", "Test and run the mouse daemon", NULL, mousedTest, NULL, NULL },
|
||||||
NULL, dmenuSubmenu, NULL, &MenuMousePort },
|
{ "4 No mouse", "Clear mouse configuration", NULL, dmenuSetVariables,
|
||||||
{ "3 Daemon", "Test and run the mouse daemon",
|
NULL, VAR_MOUSED "=NO, " VAR_MOUSED_TYPE "=NO, " VAR_MOUSED_PORT "=" },
|
||||||
NULL, mousedTest, NULL, NULL },
|
{ "0 Exit", "Exit this menu (returning to previous)", NULL, dmenuExit },
|
||||||
{ "4 No mouse", "Clear mouse configuration",
|
|
||||||
NULL, dmenuSetVariables, NULL,
|
|
||||||
VAR_MOUSED "=NO, " VAR_MOUSED_TYPE "=NO, " VAR_MOUSED_PORT "=" },
|
|
||||||
{ "0 Exit", "Exit this menu (returning to previous)",
|
|
||||||
NULL, dmenuExit },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -1248,11 +1227,10 @@ DMenu MenuNTP = {
|
|||||||
"These are the primary open-access NTP servers",
|
"These are the primary open-access NTP servers",
|
||||||
NULL,
|
NULL,
|
||||||
{ { "None", "No ntp server",
|
{ { "None", "No ntp server",
|
||||||
dmenuVarCheck, dmenuSetVariables, NULL,
|
dmenuVarsCheck, dmenuSetVariables, NULL,
|
||||||
"ntpdate_enable=NO,ntpdate_flags=" },
|
"ntpdate_enable=NO,ntpdate_flags=none" },
|
||||||
{ "Other", "Select a site not on this list",
|
{ "Other", "Select a site not on this list",
|
||||||
dmenuVarsCheck, configNTP, NULL,
|
dmenuVarsCheck, configNTP, NULL, NULL },
|
||||||
NULL },
|
|
||||||
{ "Australia", "ntp.syd.dms.csiro.au (HP 5061 Cesium Beam)",
|
{ "Australia", "ntp.syd.dms.csiro.au (HP 5061 Cesium Beam)",
|
||||||
dmenuVarsCheck, dmenuSetVariables, NULL,
|
dmenuVarsCheck, dmenuSetVariables, NULL,
|
||||||
"ntpdate_enable=YES,ntpdate_flags=ntp.syd.dms.csiro.au" },
|
"ntpdate_enable=YES,ntpdate_flags=ntp.syd.dms.csiro.au" },
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: variable.c,v 1.21 1997/10/12 16:21:21 jkh Exp $
|
* $Id: variable.c,v 1.22 1998/03/10 17:24:08 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -183,15 +183,18 @@ variable_check(char *data)
|
|||||||
if ((cp3 = index(cp, '"')) != NULL)
|
if ((cp3 = index(cp, '"')) != NULL)
|
||||||
*cp3 = '\0';
|
*cp3 = '\0';
|
||||||
}
|
}
|
||||||
if ((cp3 = index(cp, ',')) != NULL)
|
else if ((cp3 = index(cp, ',')) != NULL)
|
||||||
*cp3 = '\0';
|
*cp3 = '\0';
|
||||||
cp2 = getenv(tmp);
|
cp2 = getenv(tmp);
|
||||||
|
if (cp2) {
|
||||||
if (cp2)
|
if (!*cp)
|
||||||
|
return TRUE;
|
||||||
|
else
|
||||||
return !strcmp(cp, cp2);
|
return !strcmp(cp, cp2);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
return getenv(tmp) ? 1 : 0;
|
return getenv(tmp) ? TRUE : FALSE;
|
||||||
}
|
}
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: menus.c,v 1.159 1998/03/10 13:42:04 jkh Exp $
|
* $Id: menus.c,v 1.160 1998/03/13 11:30:44 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -341,35 +341,25 @@ DMenu MenuMouseType = {
|
|||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
{ { "Auto", "Bus mouse, PS/2 style mouse or PnP serial mouse",
|
{ { "Auto", "Bus mouse, PS/2 style mouse or PnP serial mouse",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=auto" },
|
||||||
VAR_MOUSED_TYPE "=auto" },
|
|
||||||
{ "GlidePoint", "ALPS GlidePoint pad (serial)",
|
{ "GlidePoint", "ALPS GlidePoint pad (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=glidepoint" },
|
||||||
VAR_MOUSED_TYPE "=glidepoint" },
|
|
||||||
{ "Hitachi","Hitachi tablet (serial)",
|
{ "Hitachi","Hitachi tablet (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mmhittab" },
|
||||||
VAR_MOUSED_TYPE "=mmhittab" },
|
|
||||||
{ "IntelliMouse", "Microsoft IntelliMouse (serial)",
|
{ "IntelliMouse", "Microsoft IntelliMouse (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=intellimouse" },
|
||||||
VAR_MOUSED_TYPE "=intellimouse" },
|
|
||||||
{ "Logitech", "Logitech protocol (old models) (serial)",
|
{ "Logitech", "Logitech protocol (old models) (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=logitech" },
|
||||||
VAR_MOUSED_TYPE "=logitech" },
|
|
||||||
{ "Microsoft", "Microsoft protocol (serial)",
|
{ "Microsoft", "Microsoft protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=microsoft" },
|
||||||
VAR_MOUSED_TYPE "=microsoft" },
|
|
||||||
{ "MM Series","MM Series protocol (serial)",
|
{ "MM Series","MM Series protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mmseries" },
|
||||||
VAR_MOUSED_TYPE "=mmseries" },
|
|
||||||
{ "MouseMan", "Logitech MouseMan/TrackMan models (serial)",
|
{ "MouseMan", "Logitech MouseMan/TrackMan models (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mouseman" },
|
||||||
VAR_MOUSED_TYPE "=mouseman" },
|
|
||||||
{ "MouseSystems", "MouseSystems protocol (serial)",
|
{ "MouseSystems", "MouseSystems protocol (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=mousesystems" },
|
||||||
VAR_MOUSED_TYPE "=mousesystems" },
|
|
||||||
{ "ThinkingMouse","Kensington ThinkingMouse (serial)",
|
{ "ThinkingMouse","Kensington ThinkingMouse (serial)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_TYPE "=thinkingmouse" },
|
||||||
VAR_MOUSED_TYPE "=thinkingmouse" },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -381,23 +371,17 @@ DMenu MenuMousePort = {
|
|||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
{ { "COM1", "Serial mouse on COM1 (/dev/cuaa0)",
|
{ { "COM1", "Serial mouse on COM1 (/dev/cuaa0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa0" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa0" },
|
|
||||||
{ "COM2", "Serial mouse on COM2 (/dev/cuaa1)",
|
{ "COM2", "Serial mouse on COM2 (/dev/cuaa1)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa1" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa1" },
|
|
||||||
{ "COM3", "Serial mouse on COM3 (/dev/cuaa2)",
|
{ "COM3", "Serial mouse on COM3 (/dev/cuaa2)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa2" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa2" },
|
|
||||||
{ "COM4", "Serial mouse on COM4 (/dev/cuaa3)",
|
{ "COM4", "Serial mouse on COM4 (/dev/cuaa3)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/cuaa3" },
|
||||||
VAR_MOUSED_PORT "=/dev/cuaa3" },
|
|
||||||
{ "BusMouse", "Logitech, ATI or MS bus mouse (/dev/mse0)",
|
{ "BusMouse", "Logitech, ATI or MS bus mouse (/dev/mse0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/mse0" },
|
||||||
VAR_MOUSED_PORT "=/dev/mse0" },
|
|
||||||
{ "PS/2", "PS/2 style mouse (must enable /dev/psm0)",
|
{ "PS/2", "PS/2 style mouse (must enable /dev/psm0)",
|
||||||
dmenuVarCheck, dmenuSetVariable, NULL,
|
dmenuVarCheck, dmenuSetVariable, NULL, VAR_MOUSED_PORT "=/dev/psm0" },
|
||||||
VAR_MOUSED_PORT "=/dev/psm0" },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -412,17 +396,12 @@ DMenu MenuMouse = {
|
|||||||
"Configuration menu).",
|
"Configuration menu).",
|
||||||
"Choose 3 after selecting a protocol and a port.",
|
"Choose 3 after selecting a protocol and a port.",
|
||||||
NULL,
|
NULL,
|
||||||
{ { "1 Type", "Select mouse protocol",
|
{ { "1 Type", "Select mouse protocol", NULL, dmenuSubmenu, NULL, &MenuMouseType },
|
||||||
NULL, dmenuSubmenu, NULL, &MenuMouseType },
|
{ "2 Port", "Select mouse port", NULL, dmenuSubmenu, NULL, &MenuMousePort },
|
||||||
{ "2 Port", "Select mouse port",
|
{ "3 Daemon", "Test and run the mouse daemon", NULL, mousedTest, NULL, NULL },
|
||||||
NULL, dmenuSubmenu, NULL, &MenuMousePort },
|
{ "4 No mouse", "Clear mouse configuration", NULL, dmenuSetVariables,
|
||||||
{ "3 Daemon", "Test and run the mouse daemon",
|
NULL, VAR_MOUSED "=NO, " VAR_MOUSED_TYPE "=NO, " VAR_MOUSED_PORT "=" },
|
||||||
NULL, mousedTest, NULL, NULL },
|
{ "0 Exit", "Exit this menu (returning to previous)", NULL, dmenuExit },
|
||||||
{ "4 No mouse", "Clear mouse configuration",
|
|
||||||
NULL, dmenuSetVariables, NULL,
|
|
||||||
VAR_MOUSED "=NO, " VAR_MOUSED_TYPE "=NO, " VAR_MOUSED_PORT "=" },
|
|
||||||
{ "0 Exit", "Exit this menu (returning to previous)",
|
|
||||||
NULL, dmenuExit },
|
|
||||||
{ NULL } },
|
{ NULL } },
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -1248,11 +1227,10 @@ DMenu MenuNTP = {
|
|||||||
"These are the primary open-access NTP servers",
|
"These are the primary open-access NTP servers",
|
||||||
NULL,
|
NULL,
|
||||||
{ { "None", "No ntp server",
|
{ { "None", "No ntp server",
|
||||||
dmenuVarCheck, dmenuSetVariables, NULL,
|
dmenuVarsCheck, dmenuSetVariables, NULL,
|
||||||
"ntpdate_enable=NO,ntpdate_flags=" },
|
"ntpdate_enable=NO,ntpdate_flags=none" },
|
||||||
{ "Other", "Select a site not on this list",
|
{ "Other", "Select a site not on this list",
|
||||||
dmenuVarsCheck, configNTP, NULL,
|
dmenuVarsCheck, configNTP, NULL, NULL },
|
||||||
NULL },
|
|
||||||
{ "Australia", "ntp.syd.dms.csiro.au (HP 5061 Cesium Beam)",
|
{ "Australia", "ntp.syd.dms.csiro.au (HP 5061 Cesium Beam)",
|
||||||
dmenuVarsCheck, dmenuSetVariables, NULL,
|
dmenuVarsCheck, dmenuSetVariables, NULL,
|
||||||
"ntpdate_enable=YES,ntpdate_flags=ntp.syd.dms.csiro.au" },
|
"ntpdate_enable=YES,ntpdate_flags=ntp.syd.dms.csiro.au" },
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: variable.c,v 1.21 1997/10/12 16:21:21 jkh Exp $
|
* $Id: variable.c,v 1.22 1998/03/10 17:24:08 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -183,15 +183,18 @@ variable_check(char *data)
|
|||||||
if ((cp3 = index(cp, '"')) != NULL)
|
if ((cp3 = index(cp, '"')) != NULL)
|
||||||
*cp3 = '\0';
|
*cp3 = '\0';
|
||||||
}
|
}
|
||||||
if ((cp3 = index(cp, ',')) != NULL)
|
else if ((cp3 = index(cp, ',')) != NULL)
|
||||||
*cp3 = '\0';
|
*cp3 = '\0';
|
||||||
cp2 = getenv(tmp);
|
cp2 = getenv(tmp);
|
||||||
|
if (cp2) {
|
||||||
if (cp2)
|
if (!*cp)
|
||||||
|
return TRUE;
|
||||||
|
else
|
||||||
return !strcmp(cp, cp2);
|
return !strcmp(cp, cp2);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
return getenv(tmp) ? 1 : 0;
|
return getenv(tmp) ? TRUE : FALSE;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user