Move Node::isFocusable() to Element.
authorakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 26 May 2013 05:05:37 +0000 (05:05 +0000)
committerakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 26 May 2013 05:05:37 +0000 (05:05 +0000)
commit16c74baddef6bd59a7e524b25e79106aaa9447e5
tree97a227af182623ce46c5a034d3723b889f16be9e
parent7ce6a3d726203abd71bb3f94c0d2612cf24ae749
Move Node::isFocusable() to Element.
<http://webkit.org/b/116777>

Reviewed by Anders Carlsson.

Nodes cannot be focusable, so move isFocusable() from Node to Element.

* dom/Node.cpp:
* dom/Node.h:
* dom/Element.h:
* dom/Element.cpp:
(WebCore::Element::isFocusable):

    Moved here from Node.

* dom/Document.cpp:
(WebCore::Document::setFocusedNode):
* accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::determineAccessibilityRole):

    Check that the underlying node is an Element before asking if it's focusable.

* page/FrameView.cpp:
(WebCore::FrameView::scrollToAnchor):

    Renamed the 'anchorNode' variable to 'anchorElement' because reasons.

* html/HTMLAreaElement.h:
* html/HTMLFormControlElement.h:
* html/HTMLLabelElement.h:
* html/HTMLOptionElement.h:
* svg/SVGAElement.h:

    Sprinkle OVERRIDE.

* html/ValidationMessage.cpp:
(WebCore::ValidationMessage::setMessage):

    Update a comment to refer to Element::isFocusable() instead of Node.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@150709 268f45cc-cd09-0410-ab3c-d52691b4dbfc
14 files changed:
Source/WebCore/ChangeLog
Source/WebCore/accessibility/AccessibilityNodeObject.cpp
Source/WebCore/dom/Document.cpp
Source/WebCore/dom/Element.cpp
Source/WebCore/dom/Element.h
Source/WebCore/dom/Node.cpp
Source/WebCore/dom/Node.h
Source/WebCore/html/HTMLAreaElement.h
Source/WebCore/html/HTMLFormControlElement.h
Source/WebCore/html/HTMLLabelElement.h
Source/WebCore/html/HTMLOptionElement.h
Source/WebCore/html/ValidationMessage.cpp
Source/WebCore/page/FrameView.cpp
Source/WebCore/svg/SVGAElement.h