Skip to content

Commit

Permalink
WICKET-2424 OnChangeAjaxBehavior + DatePicker do not work together
Browse files Browse the repository at this point in the history
Issue: WICKET-2424

git-svn-id: https://svn.apache.org/repos/asf/wicket/branches/wicket-1.4.x@924603 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
Igor Vaynberg committed Mar 18, 2010
1 parent c39d449 commit 3ac4c63
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
Expand Up @@ -183,6 +183,7 @@ Wicket.DateTime.init = function(cfg) {
if (cfg.hideOnSelect) cal.hide();
if (cfg.fireChangeEvent) {
var field = YAHOO.util.Dom.get(cfg.componentId);
if (field.onchangeoriginal != null && typeof(field.onchangeoriginal) != 'undefined') field.onchangeoriginal();
if (field.onchange != null && typeof(field.onchange) != 'undefined') field.onchange();
}
}
Expand Down
2 changes: 2 additions & 0 deletions wicket/src/main/java/org/apache/wicket/ajax/wicket-ajax.js
Expand Up @@ -2030,6 +2030,8 @@ Wicket.ChangeHandler=function(elementId){

var obj = Wicket.$(elementId);
obj.setAttribute("autocomplete", "off");
obj.onchangeoriginal = obj.onchange;

if (Wicket.Browser.isIE() || Wicket.Browser.isKHTML() || Wicket.Browser.isSafari()) {

var objonchange = obj.onchange;
Expand Down

0 comments on commit 3ac4c63

Please sign in to comment.