diff options
Diffstat (limited to 'include/ui.js')
-rw-r--r-- | include/ui.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/ui.js b/include/ui.js index cfdedb3..91cad7c 100644 --- a/include/ui.js +++ b/include/ui.js @@ -53,7 +53,10 @@ var UI; // Render default UI and initialize settings menu start: function(callback) { - UI.isTouchDevice = 'ontouchstart' in document.documentElement; + UI.isTouchDevice = (('ontouchstart' in window) + // required for MS Surface + || (navigator.maxTouchPoints > 0) + || (navigator.msMaxTouchPoints > 0)); // Stylesheet selection dropdown var sheet = WebUtil.selectStylesheet(); |