Virtual Key Picker
Provides a list of virtual keys such as HOME, Volume +/-, Power, etc., and allows the user to pick one.
Type key
returns a string: the code of the selected virtual key. For the full list, see Samples and Supported Key Codes.
Example
local group, name
group = 'Emulation'
name = 'key.press(key)'
return {
name = string.format('%s - %s', group, name),
description = "Release a pressed hardware key",
arguments = {
{type = 'key'},
},
default = "HOME",
generator = function(key)
return string.format('key.press(%q)', key)
end,
}