1 | if (c↵ | | 1 | Element menuElement = (Element) it.next();↵
|
2 | .getType().equals(IComponent.TYPE.TODO)) {↵ | | 2 | if (menuElement.getName().equals(MenuXMLDecoder.MENU)) {↵
|
|
3 | ITodo todo = (ITodo) c;↵ | | 3 | ↵
|
4 | Calendar sd = todo.getDtStart(↵ | | 4 | String menuId = menuElement↵
|
5 | );↵ | | 5 | .getAttributeValue(MenuXMLDecoder.ID);↵
|
|
6 | Calendar endDate = todo.getDue(↵ | | 6 | String menuName = mediator.getString("menu", "mainframe",↵
|
7 | );↵ | | 7 | menuId);↵
|
|
8 | IDateRange dr = new DateRange(startDate, endDate);↵ | | 8 | ExtendableMenu menu = new ExtendableMenu(menuId, menuName);↵
|
9 | if (startDate.equals(sd))↵ | | 9 | ↵
|
10 | result.add(id);↵ | | |
|
11 | } else↵ | | |
|
12 | throw new IllegalArgumentException(↵ | | |
|
13 | "unsupported component type " + c.getType()); | | 10 | parseMenu(menu, menuElement);↵
|
| | | 11 | menuBar.add(menu);↵
|
| | | 12 | }
|