event-deviceorientation-motion.js 544 B

1234567891011
  1. //By Shi Chuan
  2. //Part of Device Access aspect of HTML5, same category as geolocation
  3. //W3C Editor's Draft at http://dev.w3.org/geo/api/spec-source-orientation.html
  4. //Implementation by iOS Safari at http://goo.gl/fhce3 and http://goo.gl/rLKz8
  5. //test for Device Motion Event support, returns boolean value true/false
  6. Modernizr.addTest('devicemotion', ('DeviceMotionEvent' in window) );
  7. //test for Device Orientation Event support, returns boolean value true/false
  8. Modernizr.addTest('deviceorientation', ('DeviceOrientationEvent' in window) );