AX: Improve table-guessing heuristics
authordmazzoni@google.com <dmazzoni@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 18 Jan 2013 18:48:30 +0000 (18:48 +0000)
committerdmazzoni@google.com <dmazzoni@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 18 Jan 2013 18:48:30 +0000 (18:48 +0000)
commit0d2dff49df265283405fc35d1b1517a6d6d01a54
tree6bf9e6dc6ee71367be3f2d2d2769f786bb8aeba2
parent6c5cca2bd4e38ef9bf2cbf0853a11eeed85e564b
AX: Improve table-guessing heuristics
https://bugs.webkit.org/show_bug.cgi?id=107042

Reviewed by Chris Fleizach.

Source/WebCore:

Adds some more rules so that tables with cell borders, empty-cells,
col, colgroup, or >= 20 rows are all considered data tables, not
layout tables.

Test: accessibility/table-detection.html (modified)

* accessibility/AccessibilityTable.cpp:
(WebCore::AccessibilityTable::isDataTable):

Tools:

Implement parentElementCallback on Chromium to make testing easier.

* DumpRenderTree/chromium/TestRunner/src/AccessibilityUIElementChromium.cpp:
(WebTestRunner::AccessibilityUIElement::parentElementCallback):

LayoutTests:

Add tests for tables with cell borders, empty-cells,
col, colgroup, and >= 20 rows. Refactor the test to make it
easier to read the output and see whether it passed or not.

* accessibility/table-detection.html: Modified.
* platform/chromium/TestExpectations: Un-skip table-detection.html.
* platform/chromium/accessibility/table-detection-expected.txt: Added.
* platform/mac/accessibility/table-detection-expected.txt: Moved.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@140181 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/accessibility/table-detection.html
LayoutTests/platform/chromium/TestExpectations
LayoutTests/platform/chromium/accessibility/table-detection-expected.txt [new file with mode: 0644]
LayoutTests/platform/mac/accessibility/table-detection-expected.txt
Source/WebCore/ChangeLog
Source/WebCore/accessibility/AccessibilityTable.cpp
Tools/ChangeLog
Tools/DumpRenderTree/chromium/TestRunner/src/AccessibilityUIElementChromium.cpp