Chapter 10. Responding to the User

In this chapter, we will cover the following recipes:

  • Responding to simple touches
  • Responding to scroll gestures
  • Responding to manipulation gestures
  • Detecting rotate gestures
  • Responding to custom user gestures
  • Listening to sensor data
  • Listening for sensor triggers
  • Discovering the environment
  • Detecting device shakes

Introduction

Apps would not be useful if there was no way for either the user or the system to input data. The very definition of an app is to fulfil a purpose for the user, and the only way to let the app know what to do is to provide it with input. Almost all apps require some input, ranging from word processors with hundreds of key strokes and mouse clicks to screensavers, which close as soon as the mouse ...

Get Xamarin Mobile Development for Android Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.