Custom menu
Fork of Menu by
Menu.cpp@4:396eff5be1a1, 2015-03-03 (annotated)
- Committer:
- LeoHsueh
- Date:
- Tue Mar 03 03:57:46 2015 +0000
- Revision:
- 4:396eff5be1a1
- Parent:
- 3:3fceb6ff921e
Fix to use FunctionPointer.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
pyeh9 | 0:577f0ec71f4c | 1 | #include "mbed.h" |
pyeh9 | 0:577f0ec71f4c | 2 | #include "Menu.h" |
pyeh9 | 0:577f0ec71f4c | 3 | #include "Selection.h" |
pyeh9 | 0:577f0ec71f4c | 4 | |
LeoHsueh | 3:3fceb6ff921e | 5 | Menu::Menu(const char *id, Menu *parent) : menuID(id), parent(parent) |
pyeh9 | 0:577f0ec71f4c | 6 | { |
pyeh9 | 0:577f0ec71f4c | 7 | selections.clear(); |
pyeh9 | 0:577f0ec71f4c | 8 | } |
pyeh9 | 0:577f0ec71f4c | 9 | |
pyeh9 | 0:577f0ec71f4c | 10 | void Menu::add(const Selection &toAdd) |
pyeh9 | 0:577f0ec71f4c | 11 | { |
pyeh9 | 0:577f0ec71f4c | 12 | selections.push_back(toAdd); |
pyeh9 | 0:577f0ec71f4c | 13 | } |
pyeh9 | 0:577f0ec71f4c | 14 | |
pyeh9 | 0:577f0ec71f4c | 15 |