[Bug 26005] New: Selection.extend behavior when there is no range needs to be clarified

https://www.w3.org/Bugs/Public/show_bug.cgi?id=26005

            Bug ID: 26005
           Summary: Selection.extend behavior when there is no range needs
                    to be clarified
           Product: WebAppsWG
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Selection API
          Assignee: rniwa@webkit.org
          Reporter: benjamp@microsoft.com
        QA Contact: public-webapps-bugzilla@w3.org
                CC: benjamp@microsoft.com, public-webapps@w3.org

Today, the Selection API spec seems to say that if selection.rangeCount is 0,
then selection.extend should throw an error and abort. This is true in Firefox,
but not Chrome. In Chrome, it appears that a new collapsed range is created at
the position specified in selection.extend. Without an error, it's possible a
site might end up creating a selection when they think they're extending it.
But errors in JS should be used sparingly. Not sure which of these makes more
sense.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Received on Friday, 6 June 2014 17:03:02 UTC