voyent
icefaces 1.8.2 menubar component orientation not working with liferay_ tomcat 5.2.3  XML
Forum Index -> Portals & Portlets
Author Message
praful.sinha

Joined: 22/Nov/2007 00:00:00
Messages: 3
Offline


Hi,

I have use the sample code for menubar and found that the horizontal orientation is not working in any case. Please give me the solution for the same.

Here is my sample code:


<ice:portlet>

<ice:form>

<ice:panelGroup styleClass="clearer" />

<!-- main menu declaration -->
<ice:panelGroup styleClass="iceMnuBar">
<ice:menuBar id="menuBar" orientation="Horizontal" displayOnClick="true">

<!-- File menu -->
<ice:menuItem value="File" id="file" onclick="return false;">
<ice:menuItem actionListener="#{menuBar.primaryListener}"
id="open" value="Open" icon="/images/menu/open.gif">
<f:param name="myParam" value="Open" />
</ice:menuItem>
<ice:menuItem id="close" value="Close"
actionListener="#{menuBar.primaryListener}">
<f:param name="myParam" value="Close" />
</ice:menuItem>
<ice:menuItem id="recent" value="Recent"
icon="/images/menu/recent.gif"
actionListener="#{menuBar.primaryListener}">
<f:param name="myParam" value="Recent" />
<ice:menuItem id="file1" value="File 1"
actionListener="#{menuBar.primaryListener}">
<f:param name="myParam" value="File 1" />
</ice:menuItem>
<ice:menuItem id="file2"
actionListener="#{menuBar.primaryListener}" value="File 2">
<f:param name="myParam" value="File 2" />
<ice:menuItem id="para1"
actionListener="#{menuBar.primaryListener}" value="Para 1">
<f:param name="myParam" value="Para 1" />
</ice:menuItem>
<ice:menuItem id="para2" value="Para 2"
actionListener="#{menuBar.primaryListener}">
<f:param name="myParam" value="Para 2" />
</ice:menuItem>
<ice:menuItem id="para3" value="Para 3"
actionListener="#{menuBar.primaryListener}" />
</ice:menuItem>
<ice:menuItem value="File 3" id="file3"
actionListener="#{menuBar.primaryListener}">
<f:param name="myParam" value="file3" />
</ice:menuItem>
<ice:menuItem value="File 4" id="file4"
actionListener="#{menuBar.primaryListener}" />
</ice:menuItem>

<ice:menuItem id="save" icon="/images/menu/save.gif" value="Save"
actionListener="#{menuBar.primaryListener}">
<f:param name="myParam" value="save" />
</ice:menuItem>
<ice:menuItemSeparator />
<ice:menuItem id="print" icon="/images/menu/print.gif"
value="Print" actionListener="#{menuBar.primaryListener}">
<f:param name="myParam" value="Print" />
</ice:menuItem>
</ice:menuItem>

<!-- Edit menu -->
<ice:menuItem value="Edit" id="edit" onclick="return false;">
<ice:menuItem id="cut" value="Cut"
actionListener="#{menuBar.primaryListener}">
</ice:menuItem>
<ice:menuItem id="copy" value="Copy"
actionListener="#{menuBar.primaryListener}">
</ice:menuItem>
<ice:menuItem id="paste" value="Paste"
actionListener="#{menuBar.primaryListener}">
</ice:menuItem>
</ice:menuItem>

<!-- View menu -->
<ice:menuItem value="View" id="view" onclick="return false;">
<ice:menuItem id="zoom_in" value="Zoom In"
icon="/images/menu/zoomin.gif"
actionListener="#{menuBar.primaryListener}">
</ice:menuItem>
<ice:menuItem id="zoom_out" value="Zoom Out"
icon="/images/menu/zoomout.gif"
actionListener="#{menuBar.primaryListener}">
</ice:menuItem>
<ice:menuItem id="fit_in_window" value="Fit In Window"
icon="/images/menu/fitinwindow.gif"
actionListener="#{menuBar.primaryListener}">
</ice:menuItem>
<ice:menuItem id="actual_size" value="Actual Size"
icon="/images/menu/actualsize.gif"
actionListener="#{menuBar.primaryListener}">
</ice:menuItem>
</ice:menuItem>

</ice:menuBar>
</ice:panelGroup>

</ice:form>

</ice:portlet>


Thank you.
praful.sinha

Joined: 22/Nov/2007 00:00:00
Messages: 3
Offline


Hi All,

Is there any turn around for the same. I am very much in need for the Menubar of icefaces 1.8.2 in Liferay tomcat 5.2.3.
Please help me..

Thanks.
praful.sinha

Joined: 22/Nov/2007 00:00:00
Messages: 3
Offline


Hi IceSoft,

I think its a serious bug and icesoft should solve this issue because i have tried n numbers of ways in portlet, i think the menubar Rendering style and javascript is not working at any point. Also i have check the source code and i think the issue is in source code :

Check the MenuBarRenderer.java class

String defaultStyle = menuComponent.getComponentRootStyle();
if (MenuBar.ORIENTATION_VERTICAL.equalsIgnoreCase(
menuComponent.getOrientation())){
defaultStyle+=CSS_DEFAULT.MENU_BAR_VERTICAL_SUFFIX_STYLE;
}

String styleClass = menuComponent.getStyleClass();
menuDiv.setAttribute(HTML.CLASS_ATTR, CoreUtils.
addPortletStyleClassToQualifiedClass(styleClass, defaultStyle, PORTLET_CSS_DEFAULT.PORTLET_MENU));
String style = menuComponent.getStyle();
if(style != null && style.length() > 0)
menuDiv.setAttribute(HTML.STYLE_ATTR, style);
else
menuDiv.removeAttribute(HTML.STYLE_ATTR);
DOMContext.removeChildren(menuDiv);

Thank you.
 
Forum Index -> Portals & Portlets
Go to:   
Powered by JForum 2.1.7ice © JForum Team