mirror of
https://github.com/keymanapp/keyman.git
synced 2026-08-05 16:35:33 +00:00
Note: build.sh updated to make sure that test:help build action:target doesn't also call test.sh by adding `:_all` meta-target. Note: CI will need a new help-keyman-com.sh build step to deploy web engine help. Fixes: #12347
29 lines
543 B
Markdown
29 lines
543 B
Markdown
---
|
|
title: isTouchDevice
|
|
---
|
|
|
|
## Summary
|
|
|
|
Allow external callers (such as UIs) to detect if the active device is considered touch sensitive by KeymanWeb.
|
|
|
|
## Syntax
|
|
|
|
```c
|
|
keyman.util.isTouchDevice();
|
|
```
|
|
|
|
### Parameters
|
|
|
|
None.
|
|
|
|
### Return Value
|
|
|
|
`boolean`
|
|
: `true` if KMW is targetting touch-sensitivity for the device, otherwise `false`.
|
|
|
|
```
|
|
isTouchDevice ...
|
|
```
|
|
|
|
> [!Note]
|
|
> In current versions of KeymanWeb this function will return `false` for touchscreen laptops; current touch support is specialized for mobile phones and tablets.
|