googlearchive / vrview

Library for embedding immersive media into traditional websites.
http://developers.google.com/cardboard/vrview
Apache License 2.0
1.71k stars 1.09k forks source link

Hijacking arrows keys and dragging #150

Open markwoodward23 opened 7 years ago

markwoodward23 commented 7 years ago

I'm creating a slide based website based on Dragdealer that uses the arrow keys or dragging horizontally to navigate between slides. As soon as the Vrview loads on one of the slides, it hijacks the keyboard and mouse movements so I can't change slide anymore. I've tried commenting out the event listeners in embed.js, which stops the commands, but instead of allowing me to use the normal dragging and or arrow keys, it doesn't do anything.

Is it possible to change the arrows keys or remove the key binds?

tommytee commented 7 years ago

You might want to take this question to stack exchange... (since its not really a vrview issue)

The keyboard events happen in the WebVR Polyfill. https://github.com/googlevr/webvr-polyfill/blob/master/src/mouse-keyboard-vr-display.js

commenting out line 38 should work. https://github.com/googlevr/webvr-polyfill/blob/master/src/mouse-keyboard-vr-display.js#L38

Or commenting out that code directly in embed.js (which you may have already tried)

tommytee commented 7 years ago

I apologize for suggesting stack exchange / stack overflow. I recently tried to use stack overflow and discovered that it doesn't work very well.
I created a google group for questions and discussion.
https://groups.google.com/forum/#!forum/vrview-web