comparison libervia/web/pages/_browser/tools.py @ 1574:4ab4bc3ae462

browser: new `tools` module with a first method to detect touch devices
author Goffi <goffi@goffi.org>
date Wed, 22 Nov 2023 16:31:36 +0100
parents
children
comparison
equal deleted inserted replaced
1573:02432346e9b2 1574:4ab4bc3ae462
1 """Common useful tools"""
2 from browser import window
3
4
5 def is_touch_device():
6 return hasattr(window, 'ontouchstart')