The success of the iPhone has changed how people use mobile devices, with users now expecting to interact directly with a device by physically touching its screen. While a mouse is limited to the selection of a single point, iOS devices can detect multiple touches and track the movement of each of them simultaneously.
Flash provides full support for multi-touch but in order to take advantage of it you must first inform the platform of your intentions to receive and use touch-based events.
Let us see how this is done.
An FLA has been provided as a starting point for this recipe.
From the book's accompanying code bundle, open chapter5\recipe1\recipe.fla
into Flash Professional.
Sitting on the stage is a dynamic text field named output
. We will write some code to enable multi-touch input and write the success or failure of the request to the text field.