Details
-
Type:
Improvement
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.6.1
-
Component/s: ICE-Components
-
Labels:None
-
Environment:Windows XP SP2,
Weblogic 9.2
-
ICEsoft Forum Reference:
-
Affects:Documentation (User Guide, Ref. Guide, etc.)
Description
Now <ice:menuItems> have to be only inside <ice:menuBar>.
But <ice:menuItem> can contain other <ice:menuItem>.
So analogically <ice:menuItems> should be allowed to be inside <ice:menuItem>.
But <ice:menuItem> can contain other <ice:menuItem>.
So analogically <ice:menuItems> should be allowed to be inside <ice:menuItem>.
To test this feature, add the following snippets into the component-showcase:
icefaces\samples\component-showcase\src\com\icesoft\icefaces\samples\showcase\components\menuBar\MenuBarBean.java
private List menuModel;
public MenuBarBean()
{ menuModel = buildMenuModel(); }private List buildMenuModel() {
{ MenuItem sub = new MenuItem(); sub.setIcon("xmlhttp/css/xp/css-images/tree_document.gif"); sub.setValue("sub_"+i+"_"+j); mi.getChildren().add( sub ); }List list = new ArrayList();
for(int i = 0; i < 3; i++) {
MenuItem mi = new MenuItem();
mi.setIcon("xmlhttp/css/xp/css-images/tree_folder_close.gif");
mi.setValue("Dynamic " + i);
list.add( mi );
for(int j = 0; j < 3; j++)
}
return list;
}
public List getMenuModel()
{ return menuModel; }icefaces\samples\component-showcase\web\inc\components\menuBar.jspx
[Anywhere inside an ice:menuItem tag. Plus, it should also work right inside the ice:menuBar or ice:menuPopup tags]
<ice:menuItems value="#
{menuBar.menuModel}" actionListener="#
{menuBar.primaryListener}"/>