Author: amarkhel
Date: 2010-12-30 15:33:33 -0500 (Thu, 30 Dec 2010)
New Revision: 20850
Modified:
trunk/ui/output/ui/src/main/java/org/richfaces/component/AbstractDropDownMenu.java
trunk/ui/output/ui/src/main/templates/dropdownmenu.template.xml
Log:
https://issues.jboss.org/browse/RF-10109 Drop down menu: directions
Modified:
trunk/ui/output/ui/src/main/java/org/richfaces/component/AbstractDropDownMenu.java
===================================================================
---
trunk/ui/output/ui/src/main/java/org/richfaces/component/AbstractDropDownMenu.java 2010-12-30
18:21:18 UTC (rev 20849)
+++
trunk/ui/output/ui/src/main/java/org/richfaces/component/AbstractDropDownMenu.java 2010-12-30
20:33:33 UTC (rev 20850)
@@ -37,12 +37,13 @@
@Attribute(defaultValue = "250")
public abstract int getPopupWith();
-// @Attribute(defaultValue = "auto")
-// public abstract String getJointPoint();
-//
-// @Attribute(defaultValue = "auto")
-// public abstract String getDirection();
+ //TODO is it correct or cdk issue
+ @Attribute(defaultValue = "org.richfaces.component.Positioning.DEFAULT")
+ public abstract Positioning getJointPoint();
+ @Attribute(defaultValue = "org.richfaces.component.Positioning.DEFAULT")
+ public abstract Positioning getDirection();
+
@Attribute(events = @EventName("groupshow"))
public abstract String getOngroupshow();
Modified: trunk/ui/output/ui/src/main/templates/dropdownmenu.template.xml
===================================================================
--- trunk/ui/output/ui/src/main/templates/dropdownmenu.template.xml 2010-12-30 18:21:18
UTC (rev 20849)
+++ trunk/ui/output/ui/src/main/templates/dropdownmenu.template.xml 2010-12-30 20:33:33
UTC (rev 20850)
@@ -47,8 +47,11 @@
</div>
</div>
</div>
+
<script type="text/javascript">
<cdk:scriptObject name="options">
+ <cdk:call expression='addToScriptHash(options,
"direction",
((org.richfaces.component.Positioning)component.getAttributes().get("direction")).getValue())'
/>
+ <cdk:call expression='addToScriptHash(options,
"jointPoint",
((org.richfaces.component.Positioning)component.getAttributes().get("jointPoint")).getValue())'
/>
<cdk:scriptOption attributes="hideDelay showDelay popupWith
mode" />
<cdk:scriptOption attributes="onshow onhide ongroupshow
ongrouphide onitemclick" wrapper="eventHandler"/>
</cdk:scriptObject>