[w3c/screen-orientation] unlocking during event propagation is undefined (#173)

Consider:

```JS 
  promise_test(async t => {
    await test_driver.bless("request full screen", () => {
      return document.documentElement.requestFullscreen();
    });
    const newOrientation = getOppositeOrientation();
    const pMustReject = screen.orientation.lock(newOrientation);
    const pMustResolve = new Promise(r => {
      screen.orientation.onchange = () => {
        r(screen.orientation.unlock());
      };
    });
    await promise_rejects(t, new TypeError(), pMustReject);
    await pMustResolve;
    return document.exitFullscreen();
  }, "Unlocking screen orientation duruing change event causes orientationPendingPromise to reject");
```

Presumedly, calling `unlock()` during `onchange`  would cause the [[orientationPendingPromise]] to reject.  


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/screen-orientation/issues/173

Received on Thursday, 14 March 2019 08:11:05 UTC