Developing C# Apps for iPhone and iPad Using MonoTouch: iOS Apps Development for.NET Developers by Bryan Costanich

Developing C# Apps for iPhone and iPad Using MonoTouch: iOS Apps Development for.NET Developers by Bryan Costanich

Author:Bryan Costanich
Language: eng
Format: mobi
Publisher: Apress®
Published: 2011-06-27T16:00:00+00:00


Listing 12–20. Enabling touch events even when a gesture recognizer is enabled

this._tapGesture.Recognizer.CancelsTouchesInView = false;

Creating a Custom Gesture

Although the built-in gesture recognizers cover a lot of the common tasks, sometimes you want to create a custom gesture recognizer that doesn't exist. For example, let's say you want to create a checkmark gesture, whereby a user makes a “V” with their finger. In this section you're going to learn how to do just that.

Creating a custom gesture recognizer is actually fairly easy if you understand the touch events, because it's little more than a wrapper around them. You simply inherit from UIGestureRecognizer, override the touch event methods, and then bubble up your recognition status via the base class' State property.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.