Implement Gesture API

This is by no means complete, but it's a start.
Nit: this line clocks in at 335 characters! We don't need to be too restrictive, especially since Java is verbose, and a number of our files use four-space indent. But I'd try to keep lines under 120 characters.