Skip to content

Commit

Permalink
Add event handlers for sessionend events
Browse files Browse the repository at this point in the history
  • Loading branch information
Manishearth committed Oct 3, 2019
1 parent 2e577f7 commit b094ceb
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
6 changes: 3 additions & 3 deletions components/script/dom/webidls/XRSession.webidl
Expand Up @@ -39,8 +39,8 @@ interface XRSession : EventTarget {
// attribute EventHandler onblur;
// attribute EventHandler onfocus;
attribute EventHandler onend;
// attribute EventHandler onselect;
attribute EventHandler onselect;
// attribute EventHandler oninputsourceschange;
// attribute EventHandler onselectstart;
// attribute EventHandler onselectend;
attribute EventHandler onselectstart;
attribute EventHandler onselectend;
};
9 changes: 9 additions & 0 deletions components/script/dom/xrsession.rs
Expand Up @@ -291,6 +291,15 @@ impl XRSessionMethods for XRSession {
/// https://immersive-web.github.io/webxr/#eventdef-xrsession-end
event_handler!(end, GetOnend, SetOnend);

/// https://immersive-web.github.io/webxr/#eventdef-xrsession-select
event_handler!(select, GetOnselect, SetOnselect);

/// https://immersive-web.github.io/webxr/#eventdef-xrsession-selectstart
event_handler!(selectstart, GetOnselectstart, SetOnselectstart);

/// https://immersive-web.github.io/webxr/#eventdef-xrsession-selectend
event_handler!(selectend, GetOnselectend, SetOnselectend);

/// https://immersive-web.github.io/webxr/#dom-xrsession-mode
fn Mode(&self) -> XRSessionMode {
XRSessionMode::Immersive_vr
Expand Down

0 comments on commit b094ceb

Please sign in to comment.