[Webkit-unassigned] [Bug 86707] document.activeElement should not return an element not in the document tree

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jun 25 20:35:41 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=86707


Hajime Morrita <morrita at google.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #149258|review?                     |review-
               Flag|                            |




--- Comment #2 from Hajime Morrita <morrita at google.com>  2012-06-25 20:35:40 PST ---
(From update of attachment 149258)
View in context: https://bugs.webkit.org/attachment.cgi?id=149258&action=review

Hi, thanks for the patch.
The change basically looks good. I added some comments about style and small caveats.

> Source/WebCore/dom/Document.cpp:3769
> +    if (newFocusedNode && newFocusedNode->attached()) {

Using Node::inDocument() would be preferred in this case. attached() has slightly different semantics.

> LayoutTests/ChangeLog:6
> +        Reviewed by NOBODY (OOPS!).

Text test instead of ref test would be preferable in this case
because the expectation file can be less cryptic.
See "Writing JavaScript-based DOM-only Test Cases" section in http://trac.webkit.org/wiki/Writing%20Layout%20Tests%20for%20DumpRenderTree
Also, this test better fit under dom/HTMLDocument/ because the test is about activeElement.
Putting stuff directly under fast/dom is good to avoid if possible.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list