Getting Started with Toolkit Gestures

Unlike the other techniques seen in this chapter, Toolkit gestures are provided as a separate assembly, as part of the Windows Phone Toolkit package. To learn how to obtain the Toolkit, see Chapter 9.

The two main classes for working with Toolkit gestures are the GestureService and GestureListener classes. GestureService is used only to attach a GestureListener to a UIElement. Like manipulation events, Toolkit gestures are used in conjunction with a UIElement. Once attached, the GestureListener monitors the element for gestures that the element can support, such as tap, hold, pinch, and flick.

GestureListener allows you to specify handlers for each gesture type. The following example shows a Border control ...

Get Windows® Phone 8 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.