summaryrefslogtreecommitdiff
path: root/frontend/gamma/js/Zepto/detect.js
authorGiulio Cesare Solaroli <giulio.cesare@clipperz.com>2013-04-21 15:53:34 (UTC)
committer Giulio Cesare Solaroli <giulio.cesare@clipperz.com>2013-04-21 15:53:34 (UTC)
commit0608e045f6aa471916829468f48082ea07a453f4 (patch) (side-by-side diff)
tree57748b9a76e592ae35b165cd6a203e12493d4044 /frontend/gamma/js/Zepto/detect.js
parent074e70457c90344b3c1cb236105638d692a0066b (diff)
downloadclipperz-0608e045f6aa471916829468f48082ea07a453f4.zip
clipperz-0608e045f6aa471916829468f48082ea07a453f4.tar.gz
clipperz-0608e045f6aa471916829468f48082ea07a453f4.tar.bz2
Removed extra JS libraries no longer used for the mobile version
Diffstat (limited to 'frontend/gamma/js/Zepto/detect.js') (more/less context) (ignore whitespace changes)
-rw-r--r--frontend/gamma/js/Zepto/detect.js42
1 files changed, 0 insertions, 42 deletions
diff --git a/frontend/gamma/js/Zepto/detect.js b/frontend/gamma/js/Zepto/detect.js
deleted file mode 100644
index 22c0386..0000000
--- a/frontend/gamma/js/Zepto/detect.js
+++ b/dev/null
@@ -1,42 +0,0 @@
-// Zepto.js
-// (c) 2010-2012 Thomas Fuchs
-// Zepto.js may be freely distributed under the MIT license.
-
-;(function($){
- function detect(ua){
- var os = this.os = {}, browser = this.browser = {},
- webkit = ua.match(/WebKit\/([\d.]+)/),
- android = ua.match(/(Android)\s+([\d.]+)/),
- ipad = ua.match(/(iPad).*OS\s([\d_]+)/),
- iphone = !ipad && ua.match(/(iPhone\sOS)\s([\d_]+)/),
- webos = ua.match(/(webOS|hpwOS)[\s\/]([\d.]+)/),
- touchpad = webos && ua.match(/TouchPad/),
- kindle = ua.match(/Kindle\/([\d.]+)/),
- silk = ua.match(/Silk\/([\d._]+)/),
- blackberry = ua.match(/(BlackBerry).*Version\/([\d.]+)/),
- chrome = ua.match(/Chrome\/([\d.]+)/) || ua.match(/CriOS\/([\d.]+)/)
-
- // todo clean this up with a better OS/browser
- // separation. we need to discern between multiple
- // browsers on android, and decide if kindle fire in
- // silk mode is android or not
-
- if (browser.webkit = !!webkit) browser.version = webkit[1]
-
- if (android) os.android = true, os.version = android[2]
- if (iphone) os.ios = os.iphone = true, os.version = iphone[2].replace(/_/g, '.')
- if (ipad) os.ios = os.ipad = true, os.version = ipad[2].replace(/_/g, '.')
- if (webos) os.webos = true, os.version = webos[2]
- if (touchpad) os.touchpad = true
- if (blackberry) os.blackberry = true, os.version = blackberry[2]
- if (kindle) os.kindle = true, os.version = kindle[1]
- if (silk) browser.silk = true, browser.version = silk[1]
- if (!silk && os.android && ua.match(/Kindle Fire/)) browser.silk = true
- if (chrome) browser.chrome = true, browser.version = chrome[1]
- }
-
- detect.call($, navigator.userAgent)
- // make available to unit tests
- $.__detect = detect
-
-})(Zepto)