ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Mobile specific functions / Multi-Touch functions
  • Managing several pointers
  • Limitations
  • Miscellaneous
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
GestureNbPointer (Function)
In french: GesteNbPointeur
Returns the number of pointers in contact with the screen.
The returned value depends on how the function is used:
  • Used in an event linked to the movement of the pointer (click, move, pressed, released, etc.), returns the number of pointers (finger or stylus) currently in contact with the screen
  • Used in another event or process, returns the last known number of contact points.
Example
// -- Click code on an Image control
nbContactPoints is int
nbContactPoints = GestureNbPointer()
 
ToastDisplay("You are currently using " + nbContactPoints + " finger(s) on the screen")
Syntax
<Result> = GestureNbPointer()
<Result>: Integer
Number of pointers (fingers or styluses) that touch the screen.
Android Note: In the simulator or Android emulator, this number is always equal to 1..
Remarks
Android

Managing several pointers

To manage several pointers on the screen, the device must be equipped with a multi-touch display..
Caution: On some devices, the GestureNbPointer function may return a value lower than the number of pointers actually in contact with the screen.. Indeed, the number of simultaneous contact points supported by the system is limited (this limit changes according to the device).

Limitations

  • iPhone/iPadIOS WidgetMac Catalyst Up to 2 pointers can be supported.
  • WEBDEV - Browser code The browser used must support the multi-touch feature.

Miscellaneous

  • To find out the vertical position (Y) of a pointer, use GesturePosY.
  • To find out the horizontal position (X) of a pointer, use GesturePosX.
  • To get the pointer index that triggered the execution of an event linked to a movement on the screen, use GestureCurrentPointer.
Component: WDJS.DLL
Minimum version required
  • Version 17
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 09/30/2024

Send a report | Local help