| Creating Web Apps - The Touch API |
| Written by Mike James | ||||||||
| Monday, 21 January 2013 | ||||||||
Page 4 of 4
ListingThe complete listing of the final version of the program is:
What's leftThere are lots of small topcs we haven't covered. In particular we have ignored the touchenter, touchleave and touchcancel events, but these are fairly easy to work with. It is worth pointing out that there is additional information in the touch object that you can use to make your apps more sophisticated. For example, the radiusX, radiusY and rotationAngle can be used to fit an ellipse to the point of contact. The force property can also be used to work out how hard the user is pressing on the screen. Again, once you know they exist they are easy enough to use. The TouchList object also has the identifiedTouch method which can be used to return a touch object corresponding to a particular touch identifier. Perhaps another article on touch is needed? If you would like the code for this article register with I Programmer and visit the CodeBin. More Information
|
JavaScript Data Structures - A Lisp-Like List JavaScript lets you do so much with so little as we show here by implementing a Lisp-like list data structure. |
JavaScript Jems - The Revealing Constructor Pattern JavaScript should not be judged as if it was a poor version of the other popular languages - it isn't a Java or a C++ clone. It does things its own way and sometime it can do unexpectedly clever thing [ ... ] |
| Other Articles |


