Craig Davis
Posts: 0
Joined: Wed Sep 04, 2013 1:57 am

Click and touch events on iOS Build

There seems to be a problem with click / touch events and the HTML component. This seems to affect touch events such as scroll and click. Using 'virtual click' has solved some of these issues but the scroll event does not work anymore for some of my pages. Perhaps there was a change to the backend of appery or maybe jquery, would rebuild my app solve any of these problems? Everything works when tested in browser but when an xcode project is exported and tested virtually and on device thats when the problem occurs.

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Click and touch events on iOS Build

Hi Craig,

Mobile devices usually don't use a mouse so Click event doesn't make sense. They use Tap event.
VClick or Virtual Click is an artificial event created by jQueryMobile. It fires on both Click and Tap events, because generated by framework, not the device browser. Thus, using Vclick you can hope that jQueryMobile correctly recognizes your touch, as framework itself processes including Swipe event for scrolling.

Also, the possibility of page scrolling is highly dependent on the components located there, as well as on the layout and page custom styles. Touch event, which is also a scroll movement may be intercepted by other components and simply can't pass to the next levels, including to the page level, where the scroll is processed. More details about this can be found in jQueryMobile documentation on events: http://api.jquerymobile.com/category/....

Fred McIntyre
Posts: 0
Joined: Sun Jan 12, 2014 5:04 pm

Click and touch events on iOS Build

When, if ever, would it be preferable to use Click rather than Virtual Click, assuming the app is for both Android and iOS?

If Virtual Click is fired on Click events, why would I ever use Click?

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

Click and touch events on iOS Build

Hi Fred,

Use Vclick event, please find why here http://docs.appery.io/documentation/w...

Click - fires when the user clicks on an element (this is HTML event)

Virtual click - can be used instead of touch or click events, and will choose the right one depending on the platform you are running (jQuery Mobile event)

Fred McIntyre
Posts: 0
Joined: Sun Jan 12, 2014 5:04 pm

Click and touch events on iOS Build

I had read that in the docs already. I just figured that since the Click event was available, perhaps there was some reason to use it sometimes, and was just asking if there is, and when. But, I will follow your advice and ignore it and never use it. Thanks.

Return to “Issues”