Using touch events


show more Using touch events provides you with in-depth training on Developer. Taught by Joe Marini as part of the Mobile Web Design & Development Fundamentals show less
please wait ...

Using touch events

One of the really cool things about modern smartphone browsers is that you can use touch events in them. Touch events are sort of like mouse events, but there can be more than one touch point on the screen, because you're using your fingers, not using a mouse. There are four events that are sent for touch-related events. The first one is touchstart, and that's sent when a finger first touches the surface; there's touchmove, which is sent as the finger moves across the surface; there's touchend, which is sent when the finger lifts from the surface; and there's the touchcancel event, which is sent if the system cancels the touch event that's in progress.

A touch event contains a lot of information about what is happening on the screen. It contains four Boolean values, altKey, shiftKey, metaKey, and ctrlKey, which indicate whether the associated key was held down for that event. You might be saying to yourself, "Well, wait a second. How can that possibly happen on...

Using touch events
Video duration: 10m 38s 5h 47m Beginner

Viewers:

Using touch events provides you with in-depth training on Developer. Taught by Joe Marini as part of the Mobile Web Design & Development Fundamentals

Subjects:
Developer Web
Software:
HTML
Author:
please wait ...