You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Oddgeir Bell (JIRA)" <ji...@apache.org> on 2013/06/24 14:16:20 UTC

[jira] [Created] (WICKET-5249) OnChangeAjaxBehavior doesn't work with cut/paste done with mouse

Oddgeir Bell created WICKET-5249:
------------------------------------

             Summary: OnChangeAjaxBehavior doesn't work with cut/paste done with mouse
                 Key: WICKET-5249
                 URL: https://issues.apache.org/jira/browse/WICKET-5249
             Project: Wicket
          Issue Type: Bug
          Components: wicket
    Affects Versions: 6.8.0
         Environment: Windows 7, IE 10.
            Reporter: Oddgeir Bell
            Priority: Minor
         Attachments: Quickstart.zip

Add OnChangeAjaxBehavior to a text-field. In chrome/firefox, we can cut and paste using just the mouse (right-click) and it fires an ajax-call each time. In IE, i doesn't fire except when we use keyboard. Ctrl+c/Ctrl+v works, but mouse right-click and cut/paste doesn't fire an ajax event.
This is extra noticable in our case, since we had to remove the onchange-event from OnChangeAjaxBehavior. (If textfield had focus, and user clicked an ajax-button, the onchange-event fired and stopped the ajax-button-click from firing. Most likely because we have implemented a veil on ajax-calls, so the user can't click anything on the page while the ajax-event is running.)
Workaround was to add the events cut and paste:
in updateAjaxAttributes: attributes.setEventNames("inputchange paste cut");

This WILL create issues if you don't throttle the ajax (we have 200 milliseconds throttling). Without throttling, it fires twice (might or might not be a problem).

A better way would be to make the inputchange-event work properly in IE, but I have no idea why it doesn't work....


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira