[webkit-dev] Removing "type" attribute from DOMSelection

Ryosuke Niwa rniwa at webkit.org
Wed May 30 22:17:43 PDT 2012


I support this proposal. While supporting the attribute itself does not
impose much maintenance cost, the fact that our implementation is
completely different from that of IE poses a serious compatibility problem.

Also, there's an alternative to check each value of type that works on all
modern browsers:
"none" - getSelection().rangeCount() == 0
"caret" - getSelection().isCollapsed
"range" - getSelection().rangeCount() && !getSelection().isCollapsed

- Ryosuke

On Wed, May 30, 2012 at 9:58 PM, Antaryami Pandia <xqb748 at motorola.com>wrote:
>
> We plan to remove the "type" attribute from DOM selection.
> This attribute is not part of any standard specification and the current
> webkit implementation is not consistent with IE.
> I looked at Firefox's selection interface and found its not implemeted
> there (http://doxygen.db48x.net/mozilla/html/interfacensISelection.html).
>
> The webkit bug is https://bugs.webkit.org/show_bug.cgi?id=23853
>
> Please let me know, any concerns about removal of this attribute.
>
> Regards,
> -Antaryami
>
> _______________________________________________
> webkit-dev mailing list
> webkit-dev at lists.webkit.org
> http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20120530/4b0c6f95/attachment.html>


More information about the webkit-dev mailing list