+ isSecure = window.location.href.toLowerCase().indexOf("https") === 0,
+ isIOS = /iphone|ipad/.test(ua),
+ isAndroid = /android/.test(ua),
+ isTouch = (function() {
+ try {
+ if (ua.indexOf('chrome') != -1 && ua.indexOf('android') == -1) {
+ window.addEventListener('touchstart', function __set_has_touch__ () {
+ Roo.isTouch = true;
+ window.removeEventListener('touchstart', __set_has_touch__);
+ });
+ return false; // no touch on chrome!?
+ }
+ document.createEvent("TouchEvent");
+ return true;
+ } catch (e) {
+ return false;
+ }
+
+ })();