[ http://issues.apache.org/jira/browse/WICKET-96?page=comments#action_12451426 ] Gili commented on WICKET-96: ----------------------------
For AutoCompleteTextField if you hit ENTER while the pulldown menu displays it'll set the value of the textfield equal to the current selection. If, however, the menu is hidden and nothing is selected it'll do nothing and return "true" instead. I would like to be able to modify the behavior of AutoCompleteTextField such that if ENTER goes unused (i.e. the menu is hidden) then it tries submitting the form. I already have a behavior that does this, but I cannot apply it on top of AutoCompleteTextField because it "steals" the event. If we had a mechanism for allowing behaviors to register for events in a chain then one event would pick up the event if its parent in the chain did not consume it. Then I could register my EnterSubmitBehavior after the AutocompleteBehavior. > Mechanism for extensible JS-contributing behaviors > -------------------------------------------------- > > Key: WICKET-96 > URL: http://issues.apache.org/jira/browse/WICKET-96 > Project: Wicket > Issue Type: Improvement > Components: wicket > Affects Versions: 1.2.3 > Reporter: Gili > > Currently if a behavior contributes javascript code which takes control of a > control's event (i.e. onKeyPressed) there is no way to layer another behavior > on top of it such that if the first behavior does not consume the keypress > then the next behavior can make use of it. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
