code: function enterVRSuccess () {
            self.addState('vr-mode');
            self.emit('enter-vr', {target: self});
            // Lock to landscape orientation on mobile.
            if (self.isMobile && screen.orientation && screen.orientation.lock) {
              screen.orientation.lock('landscape');
            }
            self.addFullScreenStyles();
  
            // On mobile, the polyfill handles fullscreen.
            // TODO: 07/16 Chromium builds break when `requestFullscreen`ing on a canvas
            // that we are also `requestPresent`ing. Until then, don't fullscreen if headset
            // connected.
            if (!self.isMobile && !self.checkHeadsetConnected()) {
              requestFullscreen(self.canvas);
            }
  
            self.renderer.setAnimationLoop(self.render);
            self.resize();
          }
docs: Callback that happens on enter VR success or enter fullscreen (any API).