AGK for Pascal
TAgkRawTouch.FirstEvent Method

Returns an index to the first touch event available for reading.

class function FirstEvent(const IncludeUnknown: Boolean = False): Cardinal; static;
const IncludeUnknown: Boolean = False 
Set to True to receive unknown events which may become any type of event in the future. 

By default the AGK does not count an event until it knows what type of event it is, e.g. short, long, drag, etc. To receive unknown events as well set IncludeUnknown to True. Use False to ignore unknown events. All you can be sure about with unknown events is that the finger is currently on screen and has been there less than 1 second. After 1 second it automatically becomes a hold event. If the user lifts their finger off the screen it becomes a short event, and if they move their finger it becomes a drag event. 

If no events are available it returns 0. Use NextEvent to get the next event index. 

You can use the returns index with the properties that require an Index parameter (such as TouchType). 


Copyright (c) 2012. All rights reserved.