1b69bf52dSJason Hobbs /* 2b69bf52dSJason Hobbs * Copyright 2010-2011 Calxeda, Inc. 3b69bf52dSJason Hobbs * 4b69bf52dSJason Hobbs * This program is free software; you can redistribute it and/or modify it 5b69bf52dSJason Hobbs * under the terms of the GNU General Public License as published by the Free 6b69bf52dSJason Hobbs * Software Foundation; either version 2 of the License, or (at your option) 7b69bf52dSJason Hobbs * any later version. 8b69bf52dSJason Hobbs * 9b69bf52dSJason Hobbs * This program is distributed in the hope it will be useful, but WITHOUT 10b69bf52dSJason Hobbs * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11b69bf52dSJason Hobbs * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 12b69bf52dSJason Hobbs * more details. 13b69bf52dSJason Hobbs * 14b69bf52dSJason Hobbs * You should have received a copy of the GNU General Public License along with 15b69bf52dSJason Hobbs * this program. If not, see <http://www.gnu.org/licenses/>. 16b69bf52dSJason Hobbs */ 17b69bf52dSJason Hobbs 18b69bf52dSJason Hobbs #ifndef __MENU_H__ 19b69bf52dSJason Hobbs #define __MENU_H__ 20b69bf52dSJason Hobbs 21b69bf52dSJason Hobbs struct menu; 22b69bf52dSJason Hobbs 23*b41bc5a8SJason Hobbs struct menu *menu_create(char *title, int timeout, int prompt, 24b69bf52dSJason Hobbs void (*item_data_print)(void *)); 25b69bf52dSJason Hobbs int menu_default_set(struct menu *m, char *item_key); 26b69bf52dSJason Hobbs int menu_get_choice(struct menu *m, void **choice); 27b69bf52dSJason Hobbs int menu_item_add(struct menu *m, char *item_key, void *item_data); 28b69bf52dSJason Hobbs int menu_destroy(struct menu *m); 29b69bf52dSJason Hobbs 30b69bf52dSJason Hobbs #endif /* __MENU_H__ */ 31