jQWidgets Forums
jQuery UI Widgets › Forums › Editors › NumberInput › jqxNumberInput change event
This topic contains 8 replies, has 2 voices, and was last updated by spiral75 10 years, 11 months ago.
-
Author
-
Hi,
When i used jqxNumberInput change event in mobiles, the sample alert which i kept is continuously displayed. Its reproducable at http://jsfiddle.net/spiral75/eHYb7/. This is happening in all android and ios devices.Thanks
SpiralHi Spiral,
Remove the Alert. The “change” event is raised on blur. So when the Alert is opened on mobile device, the event will be raised, then you will probably close it, the focus will go to the number input again and the alert will be displayed again and will take the focus and so on and so on. So, remove the alert is the solution and use another type of event logging.
Best Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.comThanks Peter. Actually we are doing validation on ‘change’ event and if validation fails, we display a confirmation dialog box to user like “OK/CANCEL”. But after that , we are unable to goback to the screen. So is there any way to overcome this. This is happening only in mobiles. In desktops, its working fine. Also, my observation is ‘change’ event is acting as ‘valuechanged’ event in mobiles.
Thanks
SpiralHi Spiral,
The event is actually raised by the HTML Input tag. There are several possible approaches – use different validation technique. Another option is to add some IF-Else blocks inside the “change” handler or use a popup which does not take the focus from the Input tag.
Best Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.comThanks Peter. Also this an issue with the behaviour of jqxNumberInput change event on mobiles?
Thanks
SpiralHi Spiral,
I am afraid that we don’t find this to be an issue, but a standard behavior of how focus and blur works on mobile. The “change” event is always raised on blur and dialog boxes by default receive the focus when opened which means that this will cause the Input tag’s blur and so the “change” event.
Best Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.comHmm..Thanks Peter..but in “MOBILES”, change event is not raised on blur for jqxNumberInput, but its raised immediately after changing value.
Thanks
SpiralHi Spiral,
Please, don’t write incorrect information. The “change” even on mobile is raised on blur, too. Just tested your Fiddle sample. Well, if you press the Spin Up/Spin Down buttons, the event will be raised, too.
Best Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.comHi Peter,
Sorry, I was using spin buttons to change the values which i didn’t specify above. So “change” event is raised immediately after changing the value using spin buttons. If its correct behaviour in mobiles, then its fine.Thanks
Spiral -
AuthorPosts
You must be logged in to reply to this topic.