adtile / Full-Tilt

Other
316 stars 71 forks source link

Chrome 5.0 deviceorientation event handling has changed #22

Open donbarthel opened 8 years ago

donbarthel commented 8 years ago

See: https://developers.google.com/web/updates/2016/03/device-orientation-changes?hl=en

The deviceorientation event in Chrome has changed from 'world' (absolute coordinates) to 'game' (relative coordinates) matching Safari.

DeviceOrientation.js likely needs to be updated. Two options:

  1. Switch support for Chrome 5.0 to the 'game' processing. Or,
  2. Use the new deviceorientationabsolute event in Chrome 5.0 and continue to use 'world' processing.

It seems that the changes were rolled out a week ago (2016-04-25):

https://en.wikipedia.org/wiki/Google_Chrome_release_history

janrg commented 8 years ago

I'm running into the same issue I think. Safari on iPhone behaves fine but with chrome (both Android and iOS), north aligns with the orientation of the device when the page is loaded. Is this library still under development?

jasan-s commented 8 years ago

I'm on chrome mobile ver 54.0.x and I can't seem to reproduce the issue. I still get absolute data from chrome on android.

MrBlenny commented 7 years ago

Has any progress been made on this? Is there a branch (or other library) where this has been fixed?

MrBlenny commented 7 years ago

I have made a fix on my branch. World positioning on android chrome is fixed as a result.

mrotondo commented 7 years ago

Just confirmed that MrBlenny's branch fixes the currently-broken compass behavior in Chrome. Can that get turned into a pull request and integrated?