Author: pyaschenko
Date: 2008-04-15 11:25:13 -0400 (Tue, 15 Apr 2008)
New Revision: 7841
Modified:
trunk/samples/suggestionbox-sample/src/main/webapp/pages/index.jsp
trunk/ui/suggestionbox/src/main/resources/org/richfaces/renderkit/html/scripts/suggestionbox.js
Log:
http://jira.jboss.com/jira/browse/RF-3046
Modified: trunk/samples/suggestionbox-sample/src/main/webapp/pages/index.jsp
===================================================================
--- trunk/samples/suggestionbox-sample/src/main/webapp/pages/index.jsp 2008-04-15 14:39:29
UTC (rev 7840)
+++ trunk/samples/suggestionbox-sample/src/main/webapp/pages/index.jsp 2008-04-15 15:25:13
UTC (rev 7841)
@@ -80,6 +80,8 @@
height="#{suggestionBox.height}"
shadowDepth="#{suggestionBox.shadowDepth}"
cellpadding="#{suggestionBox.cellpadding}"
+ requestDelay="2000"
+ nothingLabel="nothing"
usingSuggestObjects="#{suggestionBox.usingSuggestObjects}">
<a4j:ajaxListener type="org.richfaces.AjaxListener"/>
Modified:
trunk/ui/suggestionbox/src/main/resources/org/richfaces/renderkit/html/scripts/suggestionbox.js
===================================================================
---
trunk/ui/suggestionbox/src/main/resources/org/richfaces/renderkit/html/scripts/suggestionbox.js 2008-04-15
14:39:29 UTC (rev 7840)
+++
trunk/ui/suggestionbox/src/main/resources/org/richfaces/renderkit/html/scripts/suggestionbox.js 2008-04-15
15:25:13 UTC (rev 7841)
@@ -656,7 +656,7 @@
this.prevIndex = -1;
var nothingLabel = $(this.update.id + "NothingLabel");
- if (nothingLabel) {
+ if (nothingLabel && this.hasFocus && !this.wasBlur) {
if (this.entryCount < 1) {
Element.show(nothingLabel);
Event.observe(nothingLabel, "click", this.onNothingLabelClick);