XRSession.onselectstart

The onselectstart attribute of the XRSession object is the event handler for the selectstart event, which is dispatched when user starts making some sort of selection by pressing a trigger, touchpad, or button, speaking a command, or making a hand gesture. For example, this might include pressing a button or moving a joystick.

Note: Not to be confused with XRSession.onselect and XRSession.onselectend.

Syntax

XRSession.onselectstart = function(event) { ... }

Example

XRSession.onselectstart = function(event) {
  console.log("The user has started a primary action, but might not have completed it.")
}

Specifications

Browser compatibility

Desktop Mobile
Chrome Edge Firefox Internet Explorer Opera Safari WebView Android Chrome Android Firefox for Android Opera Android Safari on IOS Samsung Internet
onselectstart
79
79
No
No
No
No
No
79
No
No
No
11.2

See also

© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/XRSession/onselectstart