AX: click point for AXHeadings often returns point on empty space (results in wrong context menu)
https://bugs.webkit.org/show_bug.cgi?id=69262
Source/WebCore:
When the contextual menu is opened for a heading, often it will open on empty space because
the heading is wider than the content inside. The click point should thus use the content
inside the heading as the click point.
To accomplish this we need to query whether we have children using children() which is a non-const
method, hence the removal of const from clickPoint().
Reviewed by John Sullivan.
Test: platform/mac/accessibility/heading-clickpoint.html
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::clickPoint):
* accessibility/AccessibilityObject.h:
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::clickPoint):
* accessibility/AccessibilityRenderObject.h:
LayoutTests:
Reviewed by John Sullivan.
* platform/mac/accessibility/heading-clickpoint-expected.txt: Added.
* platform/mac/accessibility/heading-clickpoint.html: Added.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@96520
268f45cc-cd09-0410-ab3c-
d52691b4dbfc