From fe13bd0b5e978f8a7c822e5dd4d039a5981f7204 Mon Sep 17 00:00:00 2001 From: jkh Date: Sat, 29 Apr 1995 19:33:06 +0000 Subject: o Add extra menu types (radio implemented, multiple choice shortly). o Make the framework generally more robust. o Figured out how to nest the menu descriptions - no more grotty initialization of menus. o Fix bug with helpline and helpfile not being reset. o Add stubs for the media selection code. Coming next: Fdisk and disklabel screens using Phk's new libdisk stuff. --- usr.sbin/sade/misc.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'usr.sbin/sade/misc.c') diff --git a/usr.sbin/sade/misc.c b/usr.sbin/sade/misc.c index e9a5642..4f789e2 100644 --- a/usr.sbin/sade/misc.c +++ b/usr.sbin/sade/misc.c @@ -1,7 +1,7 @@ /* * Miscellaneous support routines.. * - * $Id$ + * $Id: misc.c,v 1.1.1.1 1995/04/27 12:50:35 jkh Exp $ * * Copyright (c) 1995 * Jordan Hubbard. All rights reserved. @@ -99,9 +99,10 @@ safe_free(void *ptr) } /* - * These next two are kind of specialized just for building string lists + * These next routines are kind of specialized just for building string lists * for dialog_menu(). */ + /* Add a string to an item list */ char ** item_add(char **list, char *item, int *curr, int *max) @@ -115,6 +116,15 @@ item_add(char **list, char *item, int *curr, int *max) return list; } +/* Add a pair of items to an item list (more the usual case) */ +char ** +item_add_pair(char **list, char *item1, char *item2, int *curr, int *max) +{ + list = item_add(list, item1, curr, max); + list = item_add(list, item2, curr, max); + return list; +} + /* Toss the items out */ void items_free(char **list, int *curr, int *max) -- cgit v1.1