From 7be0213030d2ce50e618e72b5a90e4c5b63c59a4 Mon Sep 17 00:00:00 2001 From: Tom Date: Tue, 16 Aug 2011 13:19:29 +0200 Subject: checked in clean osmocombb lib --- Src/osmocombb/src/target/ui-experiment/menu.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 Src/osmocombb/src/target/ui-experiment/menu.h (limited to 'Src/osmocombb/src/target/ui-experiment/menu.h') diff --git a/Src/osmocombb/src/target/ui-experiment/menu.h b/Src/osmocombb/src/target/ui-experiment/menu.h new file mode 100644 index 0000000..d9cc97b --- /dev/null +++ b/Src/osmocombb/src/target/ui-experiment/menu.h @@ -0,0 +1,18 @@ + +/** + * Menus - menus and menu items + * + * We represent both menus and menu items in a single structure. + * + * They share the properties of having a title as well as having + * interaction callbacks such as on_select. + * + * Menus have a child item array that is indexed by menu position. + * The position of items in this array is used for numeric menu navigation. + * + */ +struct menu { + const char *title; + void (*on_select)(void); + struct menu *children[10]; +}; -- cgit v1.2.3-55-g7522