From 73a1a88c2dc464e476ca3859db98947a3479d9c8 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Thu, 17 Mar 2016 17:25:43 +0100 Subject: [PATCH] Fixed detection of proper "click" event --- wcfsetup/install/files/js/wcf.globalHelper.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wcfsetup/install/files/js/wcf.globalHelper.js b/wcfsetup/install/files/js/wcf.globalHelper.js index 48dd1d4b12..d3e16555d2 100644 --- a/wcfsetup/install/files/js/wcf.globalHelper.js +++ b/wcfsetup/install/files/js/wcf.globalHelper.js @@ -192,7 +192,7 @@ enforcing 'touchstart' on mobile devices for a better UX. We're using defineProperty() here because at the time of writing Safari does not support 'const'. Thanks Safari. */ - var clickEvent = ('touchstart' in document.documentElement) ? 'touchstart' : 'click'; + var clickEvent = ('touchstart' in document.documentElement || 'ontouchstart' in window || navigator.MaxTouchPoints > 0 || navigator.msMaxTouchPoints > 0) ? 'touchstart' : 'click'; Object.defineProperty(window, 'WCF_CLICK_EVENT', { value: clickEvent }); -- 2.20.1