From 34a6ebad406a56c13e9d77952d7640a38326a3ca Mon Sep 17 00:00:00 2001 From: John Ahlroos Date: Tue, 5 Mar 2013 10:00:53 +0200 Subject: Added IE10 touch support detection #9216 Change-Id: I3e5b2266b641901590b7806a04c6ef8c68fbe0f4 --- client/src/com/vaadin/client/BrowserInfo.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'client') diff --git a/client/src/com/vaadin/client/BrowserInfo.java b/client/src/com/vaadin/client/BrowserInfo.java index f0a4ccde0a..bddeddf74c 100644 --- a/client/src/com/vaadin/client/BrowserInfo.java +++ b/client/src/com/vaadin/client/BrowserInfo.java @@ -85,6 +85,8 @@ public class BrowserInfo { if (browserDetails.isChrome()) { touchDevice = detectChromeTouchDevice(); + } else if (browserDetails.isIE()) { + touchDevice = detectIETouchDevice(); } else { touchDevice = detectTouchDevice(); } @@ -100,6 +102,11 @@ public class BrowserInfo { return ("ontouchstart" in window); }-*/; + private native boolean detectIETouchDevice() + /*-{ + return !!navigator.msMaxTouchPoints; + }-*/; + private native int getIEDocumentMode() /*-{ var mode = $wnd.document.documentMode; -- cgit v1.2.3