Author: vmolotkov
Date: 2008-03-20 10:43:34 -0400 (Thu, 20 Mar 2008)
New Revision: 7005
Modified:
trunk/ui/combobox/src/main/config/component/combobox.xml
trunk/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
trunk/ui/combobox/src/main/templates/combobox.jspx
Log:
http://jira.jboss.com/jira/browse/RF-2604
Modified: trunk/ui/combobox/src/main/config/component/combobox.xml
===================================================================
--- trunk/ui/combobox/src/main/config/component/combobox.xml 2008-03-20 14:31:52 UTC (rev
7004)
+++ trunk/ui/combobox/src/main/config/component/combobox.xml 2008-03-20 14:43:34 UTC (rev
7005)
@@ -105,7 +105,7 @@
<defaultvalue><![CDATA[""]]></defaultvalue>
</property>
<property>
- <name>onitemselected</name>
+ <name>onselect</name>
<classname>java.lang.String</classname>
<description></description>
<defaultvalue><![CDATA[""]]></defaultvalue>
Modified:
trunk/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
===================================================================
---
trunk/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-03-20
14:31:52 UTC (rev 7004)
+++
trunk/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-03-20
14:43:34 UTC (rev 7005)
@@ -46,7 +46,7 @@
this.classes = classes;
this.isDisabled = isDisabled;
if (this.onselected) {
- this.combobox.observe("rich:onitemselected", this.onselected);
+ this.combobox.observe("rich:onselect", this.onselected);
}
if (this.isDisabled) {
this.doDisable();
@@ -297,7 +297,7 @@
this.field.value = value;
this.comboValue.value = value;
this.comboList.doSelectItem(this.comboList.activeItem);
- this.combobox.fire("rich:onitemselected", {});
+ this.combobox.fire("rich:onselect", {});
/*if (oV != value) {
this.combobox.fire("rich:onchange", {});
}*/
Modified: trunk/ui/combobox/src/main/templates/combobox.jspx
===================================================================
--- trunk/ui/combobox/src/main/templates/combobox.jspx 2008-03-20 14:31:52 UTC (rev 7004)
+++ trunk/ui/combobox/src/main/templates/combobox.jspx 2008-03-20 14:43:34 UTC (rev 7005)
@@ -194,8 +194,8 @@
]]>
</jsp:scriptlet>
<f:resource var="spacer" name="images/spacer.gif"/>
-
-<div id="#{clientId}" class="rich-combobox-font rich-combobox
#{styleClass}" style="width:#{listWidth};#{style}"
+<div id="#{clientId}">
+<div id="#{clientId}combobox" class="rich-combobox-font rich-combobox
#{styleClass}" style="width:#{listWidth};#{style}"
x:passThruWithExclusions="value,name,type,id,styleClass,class,style,size,autocomplete,disabled,onchange">
<input id="#{clientId}comboboxValue"
name="#{clientId}comboboxValue" type="hidden"/>
<div class="rich-combobox-list-cord"></div>
@@ -207,8 +207,6 @@
value="#{value}"
size="#{inputSize}"
readonly="#{enableManualInput}"
- onchange="#{component.attributes['onchange']}"
- onselect="#{component.attributes['onselect']}"
onblur="#{component.attributes['onblur']}"
style="width:#{correction}; #{inputStyle}"
autocomplete="off"
@@ -295,7 +293,7 @@
}
}
- var combobox = new Richfaces.ComboBox( "#{clientId}",
+ var combobox = new Richfaces.ComboBox( "#{clientId}combobox",
"#{clientId}list",
"#{clientId}listParent",
"#{clientId}comboboxValue",
@@ -310,9 +308,10 @@
#{filterNewValues},
#{selectFirstOnUpdate},
#{this:getAsEventHandler(context, component, "onlistcall")},
- #{this:getAsEventHandler(context, component, "onitemselected")},
+ #{this:getAsEventHandler(context, component, "onselect")},
"#{defaultLabel}",
#{disabled}, "#{value}",
#{component.attributes["showDelay"]},
#{component.attributes["hideDelay"]});
</script>
+</div>
</f:root>
\ No newline at end of file