Re: [w3c/selection-api] Fixes https://github.com/w3c/selection-api/issues/170. (PR #172)

@annevk commented on this pull request.



>          </p>
+        <section>
+          <h4>Scheduling <code>selectionhange</code> event</h4>
+          <p>To <dfn>schedule a selectionchange event</dfn> on a node <var>target</var>, run these steps:</p>
+          <ol>
+            <li>
+              If <var>target</var>'s <a>has scheduled selectionchange event</a> flag is true,
+              abort these steps.
+            </li>
+            <li>
+              <a>Queue a task</a> on the <a>user interaction task source</a> to

Oh yeah, I guess we can invoke https://html.spec.whatwg.org/#queue-a-global-task instead and obtain the global ourselves, but it seems there should be a helper for that. Maybe the primitive should be "queue an object task" where "object" has to be a "platform object". @domenic what do you think about that?

I also wonder if someone moves an element from one document to another, should we really have the global from the former document or should we use the element's node document's global object?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/selection-api/pull/172#discussion_r1527521727
You are receiving this because you are subscribed to this thread.

Message ID: <w3c/selection-api/pull/172/review/1941488865@github.com>

Received on Sunday, 17 March 2024 14:14:05 UTC