GameInputManager.Device

From Xojo Documentation

Method


GameInputManager.Device(Index as Integer) As GameInputDevice

Supported for all project types and targets.

Gets the device at the specified index and returns a GameInputDevice.

Example

This example gets the list of all the devices on the user's computer and displays them in a ListBox. mManager is a GameInputDevice instance that has been added to the window.

Var gCount, i As Integer
If mManager=Nil Then
mManager=New GameInputManager
End If
gCount = mManager.DeviceCount
For i = 0 To gCount-1
Listbox1.AddRow(mManager.Device(i).Name)
Next